News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Grab Network File

Started by RedXVII, November 02, 2006, 10:03:19 PM

Previous topic - Next topic

RedXVII

Short and sweet.
1) I dont suppose theres an easy way to copy a file from the network. Will "CopyFile" work?

2) How about from http and ftp?


Cheers all  :U
RedXVII

Ghirai

If the location is mapped to a drive, yeah, you can use copyfile.
If it's not, you can map it yourself.

As for ftp, look at some APIs exported by wininet, the're quite useful.
MASM32 Project/RadASM mirror - http://ghirai.com/hutch/mmi.html

GregL

Take a look at URLDownloadToFile for grabbing a file off of the Internet. I have used it, and it works.

PBrennick

RedXVII,
Attached is a console app that uses URLDownloadToFile as Greg suggested. This example was originally posted by Hutch, I think.

Paul


[attachment deleted by admin]
The GeneSys Project is available from:
The Repository or My crappy website

RedXVII

Thats a very very nice api.

Cheers guys!  :U  :U

P1

#5
RedXVII,

Were you referring to the Internet or LAN files?

CopyFile works for both standard DOS notation and UNC for copying files.
szSource         db "\\MORK\AC_Temps\Install\AC_Temps.exe",0

Regards,  P1  :8)

PS:  We have servers named Moe, Larry, Curly, Shemp, Ricky, Lucy.  Mork, but did not do Mindy, yet.

PBrennick

P1,
That's nice to know, about CopyFile working with UNC paths.  :U

Paul
The GeneSys Project is available from:
The Repository or My crappy website