473,320 Members | 2,080 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Connectivity thru proxy servers/Wrong path to the Internet

Hi,

We have a commercial app that downloads data from various Web pages (not via
a Web Service, per se) and parses the data from the response. The code
below works fine most of the time but, in some corporate environments --
esp. those with Proxy servers -- the app fails to get the page. That is, it
isn't just that the app doesn't logon to the proxy but, in many cases, that,
as far as we can tell, the app makes a request using a non-existent or
non-functioning Internet connection, instead of another perfectly
functioning one on the same machine. So ... two problems and questions:

1. In cases of proxies, how do we detect and automatically use them? In
many cases, it appears that the code below fails to use them and the request
ends with an exception.

'URL is something like http://www.seattleavionics.com/

wr = CType(WebRequest.Create(URL), HttpWebRequest)
Resp = CType(wr.GetResponse(), HttpWebResponse)

2. In other cases, seemingly more likely when there is a Cisco VPN
connection (even if not active, just on the system) or the user has a
cell-phone data connection that uses Fourelle Venturi (used by Verizon's
mobile data solutions), the code above seems to simply get lost finding the
Internet and, although Internet Explorer has no trouble navigating the Web,
our app's Web requests eventually ends with a timeout. It's as if .Net
decided to use the wrong path to the Internet.

My understanding was that WebRequest would automatically use the same path
to the Internet as Internet Explorer would use. That is, we didn't have to
do anything and it should just magically work. Apparently this isn't the
case. Can someone clarify when we need to explicitly set the Proxy and when
we don't? And does anyone have any clue as to what is going on w/ #2?

Finally, does the code below look correct for manually setting a proxy?

Dim proxy As New Net.WebProxy(ProxyURL)
proxy.Credentials = New Net.NetworkCredential(Username, Password)
wr = CType(WebRequest.Create(URL), HttpWebRequest)
wr.Proxy = Proxy
Resp = CType(wr.GetResponse(), HttpWebResponse)

BTW -- If anyone is a pilot, free flight planning software for life if you
solve this one for us!

Thanks, Steve
www.seattleavionics.com
Nov 20 '05 #1
0 1797

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Fuzzyman | last post by:
I'm trying to create a proxy server - one that will modify requests made through it. I've started with Tiny HTTP Proxy by SUZUKI Hisao which is built on BaseHTTPServer - and I'm starting to get...
3
by: Sebastián | last post by:
Hi all! I have an app that needs to connect to internet thru a proxy. Does anybody knoe how should I write the credentials for my proxy? Thanks in advance, Sebastián
13
by: Xah Lee | last post by:
the Journey of Foreign Characters thru Internet Xah Lee, 20051101 There's a bunch of confusions about the display of non-ascii characters such as the bullet "•". These confusions are...
3
by: Soul | last post by:
Hi, I am learning to code a WinForm application which will need to access a Web Service outside the University network. Our University require us to go through a proxy in order to access the...
10
by: Abubakar | last post by:
hi, I work on a computer that is part of a network and uses proxy to connect to net. I cant connect to servers outside my proxy with simple ConnectTo code. I need to know how to make my requests go...
3
by: Wild Wind | last post by:
Hello all, I apologise in advance for the long windedness of this post, but I feel that if I am going to get any solution to this problem, it is important that I present as much information...
5
by: SK | last post by:
Hi, We have 2 Servers in our Production Environment. Inside our application I am calling a Webservice in Production Server 2 from Production Server 1. It is failing. But when I try to open...
10
by: Jim | last post by:
I have seen http://www.vbdotnetheaven.com/Code/Aug2003/2146.asp - but it does not work. I need a working example....if anyone has seen one. Jim
0
by: okonita | last post by:
Hi all, I am having a DB2 connectivity problem that I hope someone can help me resolve. I need this to test Replication and such other things. What am I doing wrong here? Any help that I can get...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shćllîpôpď 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.