views:

1865

answers:

3

I'm behind a firewall at work at the moment and I was testing something that I had deployed to my website, and the work proxy seems to be blocking it somewhat.

Basically I am getting a message of:

Operation is not valid due to the current state of the object

I've got it down to my proxy interferring, but I can't see any advanced settings or anything I can set up to go through my proxy to get to my service.

I did a quick google for it, but no joy.

Anyone found a quick way to get around it?

+1  A: 

Edit, I forgot to write this part in the answer: You may need to add the web reference url to the safe list for your proxy. I am not sure what proxy you are using or if you have control of it, but this should solve your problem. If you don't have access to change the proxy, then I put a quick work around right below.

Here's a quick work around, just use the browser to navigate to the WSDL. Grab the xml and save it as a .wsdl file on your computer you would like to generate the client on. Then use the wsdl.exe to generate the client pointing it to the path you saved the wsdl file.

Dale Ragan
A: 

Thanks @Dale!

Checking out wsdl.exe it also has optional parameters to define a proxy as well, but your suggestion seems to work :)

crucible
A: 

Hi,

Another option is to go to your application's web config/ app config and add the following under the element:

http://someproxy:someport bypassonlocal="True"/>

Thanks, Gaurav