Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Download text file from website
Message
From
14/10/2004 06:49:08
Metin Emre
Ozcom Bilgisayar Ltd.
Istanbul, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00941665
Message ID:
00951325
Views:
12
Hi Anatoliy,

Nice code. I saved it too. :)

>Hi Bill,
>
>The following code downloads robots.txt file from http://www.microsoft.com
>
>DECLARE INTEGER URLDownloadToCacheFile IN urlmon;
>	INTEGER lpUnkcaller, STRING szURL, STRING @szFileName,;
>	INTEGER dwBufLength, INTEGER dwReserved, INTEGER pBSC
>
>LOCAL cRequest, nResult, cTargetFilename
>cTargetFilename = Repli(Chr(0), 250)
>cRequest = "http://www.microsoft.com/robots.txt"
>
>WAIT WINDOW NOWAIT "Downloading remote file..."
>nResult = URLDownloadToCacheFile(0, cRequest,;
>	@cTargetFilename, Len(cTargetFilename), 0,0)
>	
>cTargetFilename = STRTRAN(cTargetFilename, Chr(0), "")
>IF FILE(cTargetFilename)
>	MODIFY FILE (cTargetFilename) NOWAIT
>ENDIF
>
>WAIT CLEAR
>
Previous
Reply
Map
View

Click here to load this message in the networking platform