Chia sẻ

The Directory.SetCreationTime and Directory.GetCreationTime methods are used to set and get the creation date and time of the specified directory. The following code snippet sets and gets the creation time of a directory.

string root = @"C:Temp";
// Get and Set Creation time
Directory.SetCreationTime(root, DateTime.Now);
DateTime creationTime = Directory.GetCreationTime(root);
Console.WriteLine(creationTime);

 

ĐĂNG KÝ MUA HÀNG

    Email (*)

    Điện thoại (*)

    Tên sản phẩm/Dịch vụ:


    Chia sẻ
    Xem thêm  [C#] How to Decrypt a File in C#

    Leave a Reply

    Your email address will not be published. Required fields are marked *