The remote server returned an error: (500) Internal Server Error. #3

I am trying to access a web site using below snippet

HttpWebRequest httpWebRequest = (HttpWebRequest)WebRequest.Create(url);

HttpWebResponse webResponse = (HttpWebResponse)httpWebRequest.GetResponse();

This is occuring for particular web site and rest of the web site working fine. 

Error:

 The remote server returned an error: (500) Internal Server Error. at System.Net.HttpWebRequest.GetResponse() -532459699... 

Also, i tried with below options

1. Adding Credential like

NetworkCredential networkCredential = new NetworkCredential("user name", "pwd", "domain");

httpWebRequest.Credentials = networkCredential;

2. Adding below User Agent. 

httpWebRequest.UserAgent = "Mozilla/5.0+";

When i try to access the URL from IE, its working fine. Please help me.


Thanks and Regards,
Saravana Prakash P.
http://saravanaprakashp.blogspot.com
Trust in Technology
0
PSP_152890
4/1/2009 9:33:23 AM
asp.net.getting-started 91979 articles. 2 followers. Follow

4 Replies
755 Views

Similar Articles

[PageSpeed] 34

Mostly this error occcurs coz of the proxy settings...did u try setting proxy from ur code? 


Please mark as answer if it helped u!
0
kavita_khandhadia
4/1/2009 9:40:08 AM

Thanks for your reply.

How do we set the proxy in the code and any reason for setting proxy since the same url is working in normal IE.

 


Thanks and Regards,
Saravana Prakash P.
http://saravanaprakashp.blogspot.com
Trust in Technology
0
PSP_152890
4/1/2009 9:57:05 AM

try

http://persistall.com/archive/2005/09/17/19.aspx


News & Reviews | Matrimonial | Mithila

0
hs_jha
4/1/2009 10:23:02 AM

I think, proxy is not an issue. I tried, getting unable to resolve remote server error. Any other solution please.


Thanks and Regards,
Saravana Prakash P.
http://saravanaprakashp.blogspot.com
Trust in Technology
0
PSP_152890
4/1/2009 11:59:26 AM
Reply:

Similar Artilces:

System.Net.WebException: The remote server returned an error: (500) Internal Server Error.
I have written a web service and tested it and it works fine from the .asmx test page. However, when I attempt to call it with a post I get this error:  The remote server returned an error: (500) Internal Server Error. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Net.WebException: The remote server returned an error: (500) Internal Server Error.Source Error: Line 164: myStream.Close() ...

Web Service Error : The remote server returned an error: (500) Internal Server Error
Hi i am getting an error when trying a simple web service. if i run both the web service and the client .aspx page on the same server it works fine, But when i put it on a different server it doesnt work at all and gives me this error"System.Net.WebException: The remote server returned an error: (500) Internal Server Error. at System.Net.HttpWebRequest.GetResponse() at HttpUtils.HttpPost(String URI, String Parameters) in e:\Websites\C#\Live\CMS\Trunk\App_Code\siteFunctions\HttpUtils.cs:line 35"UserApi.asmx  [WebMethod] public string HelloName(string name) { ...

The remote server returned an error: (500) Internal Server Error
I have a VB.Net application where I am posting to an HTTP server that has a classic asp page and I am getting the following exception (it's throwing the exception on line 13).  Does anyone know how to troubleshoot this?  thanks  : <EXCEPTION> The remote server returned an error: (500) Internal Server Error </EXCEPTION> 1                            PostData = "externalID=" ID2 Dim strPath As ...

he remote server returned an error: (500) Internal Server Error.
Hi, I would like to connect a webservice. But I don't want to use "add web reference" -------------------------------------------------------------------------------------------- string strSoapMessage = "<?xml version='1.0' encoding='UTF-8'?>" + "<soap:Envelope xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>"+ "<soap:Body>"+ "<GenerateSessionKey xmlns='http://www.artwork-systems.com/webway/sessions'>"+ "<login>test</login>"+ "<auth>test<...

remote server returned an error: (500) Internal Server Error.
Hi Frnds, I have Using HTTP Post Method ,Already create Webconfig fine(  <webServices>      <protocols>        <add name="HttpGet"/>        <add name="HttpPost"/>      </protocols>    </webServices> )But i got  remote server returned an error: (500) Internal Server Error. i am not using SOAP.. public void Post()        {      ...

The remote server returned an error: (500) Internal Server Error.
 System.Net.WebException: The remote server returned an error: (500) Internal Server Error.     i implemented the search functionality in the website searchdotnet some application i got ,i inegrated it ,it works fine localhost but on server i created some problemMark As Answer If my reply helped you. It means that an exception occured , you can specify in the web.config to show the exact exception to remote hosts.what is the <customErrors> configuration in your web.config ?   J.W.Please click "Mark as Answer" on this post if it helps you...

The remote server returned an error: (500) Internal Server Error
Hi  String strUrl = "http://catalogues.cataloguecentral.com.au/global/search/search.aspx?";              // Create a request using a URL that can receive a post.         WebRequest request = WebRequest.Create(strUrl);        // Set the Method property of the request to POST.        request.Method = "POST";        // Create POST data and convert it to a byte array. &...

The remote server returned an error: (500) Internal Server Error.
When I remote access in website by application on window to extract data I have error : The remote server returned an error: (500) Internal Server Error. This is my code : Dim PostData As String = _ "__VIEWSTATE=" & tmpvs & _ "&txtUserName=" & UserID & _ "&txtPassword=" & PWord & _ "&chkPersistant=1" & _ "&btnSignIn=SignIn" '& _ Dim Data() As Byte = encoding.GetBytes(PostData) Dim LoginReq As Net.HttpWebRequest = Net.WebRequest.Create(loginURL) With LoginReq .KeepAlive = Fals...

The remote server returned an error: (500) Internal Server Error. #2
I am testing a utility program that loops through my localhost and pulls out all of the meta tag information and page titles.   After I do a recursive directory search and have all of the pages i convert the directory path's to urls and call the pages using the following code WebClient wc = new WebClient(uri); string page = wc.DownloadString(uri); This seems to work fine for the first few sites, however at a certain point i start getting (The remote server returned an error: (500) Internal Server Error.).  Nothing is wrong with the URI however it just seems to st...

The remote server returned an error: (500) Internal Server Error #2
Hello, I'm trying to send the request from site A to site B in localhost but get an error "The remote server returned an error: (500) Internal Server Error" in programatically.  The code below used to work for me and all of a certain it fails to send the request to site B (order site). The order site by itself is still up and running but when I try to send the request to this site in the code, it fails because of (500) Internal Server Error.  I also tried to restart the IIS but still doesn't work.  Does anyone knows why?  mReqUrl =...

Message="The remote server returned an error: (500) Internal Server Error."
 HI,when I try to call a simple web method with parameters using HTTP Post I am getting this error "Message="The remote server returned an error: (500) Internal Server Error.""  This My Web Method [WebMethod]        public string getDataWithParm1(string aaa)        {            string ss= "yytry";            ss =ss + " asdfg" ;            r...

How to solve:"The remote server returned an error: (500) Internal Server Error. "
 I am working On asp.net2.0(c#) In creating rss i used a user control by writing xml dynamically. It is working well in my personal server but in my client server it is producing error such that.. Server Error in '/GetReception' Application. The remote server returned an error: (500) Internal Server Error. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Net.WebException: The remote server return...

Server Error: HTTP Error 500.19
I got the following error while trying to make a test WCF project on VistaServer Error HTTP Error 500.19 - Internal Server ErrorDescription: The requested page cannot be accessed because the related configuration data for the page is invalid. Error Code: 0x80070005 Notification: BeginRequest Module: IIS Web Core Requested URL: http://localhost:80/ProductsService/ProductsService.svc Physical Path: C:\Test\ProductsService\ProductsService\ProductsService.svc Logon User: Not yet determined Logon Method: Not yet determined Handler: Not yet determined Config Error: Cannot read configura...

getting error like
hello  Using Ajax 1.0 RC I’m getting this error:Sys.WebForms.PageRequestManagerServerErrorException Error: an unknown error occurred while processing the request on the server. the status code return from the server was 403I have one update panel in which i have gridview control. i have sorting true in gridviewwhen i click on header for sorting and wait for the result. it display updateprogress and working fine as expected.but if i click for sorting on header continueously without stoping after 10 or 12 click it gives me above error. I am struckup heremy code is like this:<asp:Update...

Web resources about - The remote server returned an error: (500) Internal Server Error. #3 - asp.net.getting-started

Energy returned on energy invested - Wikipedia, the free encyclopedia
The natural or original sources of energy are not usually included in the calculation of energy invested, only the human-applied sources. For ...

How Facebook Returned A/B Testing To Mobile Apps
When Facebook rewrote its mobile applications and converted them from custom Web stacks to native development stacks, it lost the ability to ...

Facebook temporarily reveals ‘returned value’ metric for ads
Some Facebook advertisers temporarily saw a new metric called “returned value” in their Ads Manager dashboard. Facebook says the metric was accidentally ...

The Night Steve Jobs returned to Apple, Dec 20, 1996 - a set on Flickr
Working late on a Friday on December 20th at Apple Computer as Mac OS Evangelist, my manager came rushing past my office door saying to come ...

Batista reveals why he returned to WWE - YouTube
The Animal talks about overcoming a broken back, his immersion in Jiu-Jitsu training, and his desire to capture the WWE World Heavyweight Championship. ...

Fugitive US businessman Zack Shahin returned to UAE, says spokesman
... a taser following his release. A fugitive American businessman who is facing multi-million dirham corruption charges in Dubai has been returned ...

Bender is back! Belair’s favourite robot returned - AdelaideNow Search Search
GOOD news, everyone! Bender the robot — possibly the coolest letterbox in the Adelaide Hills — has been returned just days after being stolen. ...

War memento returned: 'It was like him coming home'
The home-made memento, fashioned into the shape of Australia and fastened around Richard Moffat's wrist with a length of leather, could have ...

Australian diplomat returned from posting after husband charged over child-sex allegations
One of Australia's top diplomats has returned early from an overseas posting after her spouse was arrested and charged with child sex offences.&nbsp; ...

Perth student’s camera returned after five years on bottom of Prague river
IT took a Beatles lyric, an aquatics instructor and social media to return Chloe Hutson’s long-lost holiday photographs five years after her ...

Resources last updated: 12/30/2015 7:06:50 PM