>Hello alls.
>It´s my firts time work with Visual Basic and I dont know how:
>- Conect a network drive
You can use the Wscript.Network object to map a UNC to a local drive using the MapNetworkDrive method, or the Win32 API call WNetAddConnection2()
>- copy file (The name of the files depends of the date,for example: PB120200.
>How read the month, the day, and the year.)
Both are handled by the Scripting.FileSystemObject, as well as by native VB functions. You can get the file and copy it, and look at all three of the date/time stamps if they're published. You can use the API CopyFile() or SHFileOperation() API calls. You can open the file for low-level I/O reading the existing file and writing the data to a new file. Lots of ways.
>- Disconect a network drive
WSH RemoveNetworkDrive method or WNetCancelConnection() in the API
I recommend the WSH objects for ease of use and greatest functionality.