Exemplo n.º 1
0
        // Get the UTC last access time of a directory.
        public static DateTime GetLastAccessTimeUtc(String path)
        {
            long time;

            ValidatePath(path);
            HandleErrorsDir(DirMethods.GetLastAccess(path, out time));
            return(new DateTime(time));
        }
Exemplo n.º 2
0
        // Get a file's UTC last access time.
        public static DateTime GetLastAccessTimeUtc(String path)
        {
            long ticks;

            Directory.ValidatePath(path);
            Directory.HandleErrorsFile
                (DirMethods.GetLastAccess(path, out ticks));
            return(new DateTime(ticks));
        }