Tag Archives: modification time

Get and set file times in C#

The File class provides methods that get and set file times including the creation, modification, and access times. The following code shows how the example uses those methods to get and set a file’s times. // Get the file’s times. … Continue reading

Posted in files | Tagged , , , , , , , , , , , , , , , | Leave a comment

Get file size and last modification time on an FTP server in C#

The FtpGetFileSize method shown in the following code gets a file’s size in bytes. The uri parameter gives the full path to the file as in ftp://www.somewhere.com/test.txt. Note that the URI must begin with ftp not http. // Use FTP … Continue reading

Posted in files, ftp, internet, web | Tagged , , , , , , , , , , , , , , | Leave a comment