View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
c mateland c mateland is offline
external usenet poster
 
Posts: 52
Default Code to do a Web-download

In an addin I employ some commonly used Web-download code as shown
below:


Public Function DownloadFile(sDlNetFileAddy As String, _
sDlUserPath As String) As Boolean
DownloadFile = URLDownloadToFile(0&, sDlNetFileAddy, _
sDlUserPath, BINDF_GETNEWESTVERSION, 0&) = ERROR_SUCCESS
DoEvents
End Function


Along with the supporting code, it works well, but my concern is for
those people with really slow connections. I'm concerned it may cause a
runtime error if it takes too long.

Any thoughts on this? Is there a way I can set a timeout variable?

Thanks,
Chuck