![]() |
NetworkCredential
Hello, guys... What is the Java equivalent class for NetworkCredential?
Please reply. Thanks |
Re: NetworkCredential
NetworkCredential by that way is a C# class.
|
Re: NetworkCredential
"IveCal" <ive.cal@gmail.com> wrote in message
news:1145246622.484974.197000@u72g2000cwu.googlegr oups.com... > Hello, guys... What is the Java equivalent class for NetworkCredential? > Please reply. Thanks > Crosspost; don't multipost: http://www.cs.tut.fi/~jkorpela/usenet/xpost.html - Oliver |
Re: NetworkCredential
On Mon, 17 Apr 2006 17:05:30 GMT, "Oliver Wong" <owong@castortech.com>
wrote, quoted or indirectly quoted someone who said : > Crosspost; don't multipost: >http://www.cs.tut.fi/~jkorpela/usenet/xpost.html wasn't it you in that last post on the futility of making Internet requests? -- Canadian Mind Products, Roedy Green. http://mindprod.com Java custom programming, consulting and coaching. |
Re: NetworkCredential
"Roedy Green" <my_email_is_posted_on_my_website@munged.invalid > wrote in message news:7t8842ppf0rardgkp86pmrkkb2pi1rj08o@4ax.com... > On Mon, 17 Apr 2006 17:05:30 GMT, "Oliver Wong" <owong@castortech.com> > wrote, quoted or indirectly quoted someone who said : > >> Crosspost; don't multipost: >>http://www.cs.tut.fi/~jkorpela/usenet/xpost.html > > wasn't it you in that last post on the futility of making Internet > requests? Yes. I bet no matter how many times I post the above advice, we'll always see another user make another multipost. - Oliver |
Re: NetworkCredential
The code snippet below shows the use of NetworkCredential...
I'm curious over the object (networkCredential in this case) it creates because it was used once only for authentication purposes... (exactly before accessing the webpage...) Do you have any idea how is this going to be implemented in Java? Thanks... void Page_Load(Object sender, EventArgs e) { XmlDocument doc = new XmlDocument(); NetworkCredential networkCredential = new NetworkCredential("username","password"); ==> THIS IS WHAT I MEAN... HttpWebRequest HttpWReq = (HttpWebRequest)WebRequest.Create( "http://api.keyworddiscovery.com/free.php?q=" + HttpUtility.UrlEncode(Request.Form["query"]) ); HttpWReq.PreAuthenticate = true; HttpWReq.Credentials = networkCredential; HttpWebResponse HttpWResp = (HttpWebResponse)HttpWReq.GetResponse(); if (HttpWResp.StatusCode == HttpStatusCode.OK) { doc.Load(HttpWResp.GetResponseStream()); } XslTransform trans = new XslTransform(); trans.Load(Server.MapPath("output_template.xsl")); xml1.Document = doc; xml1.Transform = trans; } |
Re: NetworkCredential
"IveCal" <ive.cal@gmail.com> wrote in message
news:1145515970.769410.137350@i39g2000cwa.googlegr oups.com... > The code snippet below shows the use of NetworkCredential... To the OP: Did you read the link at http://www.cs.tut.fi/~jkorpela/usenet/xpost.html ? I posted an answer to you in another newsgroup already. To Roedy: I told you so. - Oliver |
| All times are GMT. The time now is 03:45 PM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.