Questions tagged [webexception]
81 questions
1
vote
2 answers
System.Net.WebException: An SSL error has occurred and a secure connection to the server cannot be made
Already found the same thread here, but that not resolved my problem.
I have added NSAppTransportSecurity and NSAllowsArbitraryLoads in info.plist.
Screenshot:
Added the below codes from this article.
NSAppTransportSecurity
…

Sreejith Sree
- 3,055
- 4
- 36
- 105
1
vote
0 answers
Get WebExceptions Headers on Load Balancer Server
We are using one load balance Server which redirect us to another four different server and other two servers which are not on the farm of load balance server. The configuration looks like completed perfectly from the administrator of the…

Senior .Net Dev3loper
- 111
- 1
- 1
- 9
1
vote
2 answers
HttpWebRequest throws ConnectFailure on the real device but not on emulator for Windows Handheld 6.5
I'm having similar issues to this link No Internet on the device via code
I am working on the Intermec iRoc Ci70 device which is running on Windows Handheld Embedded 6.5. This device has the 802.11abgn Wireless LAN adapter.
On the device emulators…

Duy Le
- 21
- 7
1
vote
1 answer
Unhandled Exception in Xamarin Android When Using HttpWebResponse
I have the following code:
public async Task
- > GetBot(string token)
{
var menulist = new List

Morteza Zabihi
- 2,884
- 1
- 20
- 20
1
vote
1 answer
The remote name could not be resolved: 'localhost'
How can the application not be able to lookup localhost?
The remote name could not be resolved: 'localhost';
StackTrace;
at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
at…

jgauffin
- 99,844
- 45
- 235
- 372
1
vote
1 answer
Adding a catch to ignore 404 web exception (C#)
I am writing an app to scrape my website for keywords. I am running into an issue where if I try to read a page that does not follow through I get a 404 (not a problem).
However when my app encounters the 404 web exception it does not continue. I…

Jeremy Roberts
- 11
- 2
1
vote
0 answers
How to fix "System.Net.WebException: The operation has timed out" error from .Net 1.1 Framework
Our ASP.Net 1.1 WebService application is hosted in Windows 2003 Server.
Another .Net Windows Service application is calling the Webservice hosted in the above server every 30 seconds.
We have added a retry call mechanism if any network error…

Sudharsan G
- 11
- 1
- 3
1
vote
3 answers
Handling WebException with Queue
I have a little C# project it send unique data with WebRequest on an internet site and get back a HttpWebResponse. Now I want to handle the situation with no internet connection or other thinks the data could not send or receive.
In my opinion its…

Denis
- 439
- 4
- 17
1
vote
1 answer
C# Unhandled Exception using try catch block
I'm getting a System.Net.WebException saying:
The remote server returned an error: (403) Forbidden.
This is what I'm expecting since invalid headers are being passed in with the http request. However, my code does not seem to be catching the…

Jared Price
- 5,217
- 7
- 44
- 74
1
vote
1 answer
C# WebException Error: 530 (not logged in)
I need some help with some code that is not working for some reason. I'm making a method that gets a list of files in a FTP directory. Every time I debug the app, a WebException is thrown with the StatusCode of 530 (not logged in). Keep in mind…

Greg Whatley
- 1,020
- 1
- 13
- 32
1
vote
2 answers
Amazon AWS: Failing to Login
I've been working on an amazon EC2 project and when I login like this:
public bool Login(Credentials credentials, string ownerID, string region)
{
try
{
OwnerID = ownerID;
CurrentCredentials = credentials;
…

Matheus Simon
- 668
- 11
- 34
1
vote
1 answer
Sql Exception not handled by exception class
Its found that sometimes some web exceptions and sql Exceptions are not handled by Exception class. I know that should not happen. But on production I found that issue, unable to reproduce on my local computer.
try{
//some code
}
catch (Exception…

Rohit
- 300
- 2
- 14
1
vote
1 answer
what make ex.Response returns null
I'm scanning a single url that has many paths example: http://url.com/path1 to 1000. Sometimes I get a WebException but in my catch block, it will throw a NullReferenceException error if I don't use the line
if (x.Status ==…

terrala7
- 65
- 1
- 8
1
vote
1 answer
Status code 301 not showing correctly in C#
I am able to get numbers with enum as suggested by dtb in Getting Http Status code number (200, 301, 404, etc.) from HttpWebRequest and HttpWebResponse. However, for moved permanently site also i am getting 200 (OK). What I want to see is 301…

aditya
- 333
- 1
- 6
- 11
1
vote
1 answer
WebRequest handshake fails due to unexpected packet format
I have a number of ASP.NET websites and a webservice that use the same code to "login" to a third party website. This includes basically using a WebRequest to do a HTTP POST to the login page of the website with my credentials, storing the resulting…

Nick Thissen
- 1,802
- 4
- 27
- 38