How do I read the modify date of the file in C#?
I can read the creation date of the file by using the code below:
ModifyDate = File.GetCreationTime(FilePath)
Getting the File Creation Date Using debugfs We can also use the debugfs command to find the creation date on ext4 filesystems. However, it is not as intuitive as the stat command since its primary purpose is to debug filesystems. Firstly, we need the inode number of our file. We can find it with the ls command.
File.GetLastWriteTime will do the job
I believe you're looking for GetLastWriteTime
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With