SetEntryTimes Method (created, accessed, modified)

DotNetZip

Ionic Zip Library v1.9.1.6 SetEntryTimes Method (created, accessed, modified)
ReferenceIonic.ZipZipEntrySetEntryTimes(DateTime, DateTime, DateTime)
Sets the NTFS Creation, Access, and Modified times for the given entry.
Declaration Syntax
C# Visual Basic Visual C++
public void SetEntryTimes(
	DateTime created,
	DateTime accessed,
	DateTime modified
)
Public Sub SetEntryTimes ( _
	created As DateTime, _
	accessed As DateTime, _
	modified As DateTime _
)
public:
void SetEntryTimes(
	DateTime created, 
	DateTime accessed, 
	DateTime modified
)
Parameters
created (DateTime)
the creation time of the entry.
accessed (DateTime)
the last access time of the entry.
modified (DateTime)
the last modified time of the entry.
Remarks

When adding an entry from a file or directory, the Creation, Access, and Modified times for the given entry are automatically set from the filesystem values. When adding an entry from a stream or string, the values are implicitly set to DateTime.Now. The application may wish to set these values to some arbitrary value, before saving the archive, and can do so using the various setters. If you want to set all of the times, this method is more efficient.

The values you set here will be retrievable with the ModifiedTime, CreationTime and AccessedTime properties.

When this method is called, if both EmitTimesInWindowsFormatWhenSaving and EmitTimesInUnixFormatWhenSaving are false, then the EmitTimesInWindowsFormatWhenSaving flag is automatically set.

DateTime values provided here without a DateTimeKind are assumed to be Local Time.

Assembly: Ionic.Zip (Module: Ionic.Zip) Version: 1.9.1.8 (1.9.1.8)