Ok so..
I need to read a command from a .html file. To do this I use:
Code:
  Dim instance As WebClient = New WebClient
   Dim address As String = "www.siteurl.com/file.html"
                    Dim returnValue As String


                returnValue = instance.DownloadString(address)




                If returnValue = "open" Then
                  BLAHBLAHBLAH
I need this to run flawlessly, regardless if the my internet is on or not. If the internet disconnects, I get this (While Debugging):


returnValue = instance.DownloadString(address)
Unable to connect to the remote server


Question:
My application constantly loops to check the .html file for commands.
I need it to do this, even if the internet is off. Obviously, it wont read commands if its off.. I just need it to resume reading when it comes back on WITHOUT crashing my application.


Any code to ignore timeouts so where my application will still TRY to read and not crash.