|
<< Click to Display Table of Contents >> Navigation: Programming Mechworks PDM > DBWCommandShell > Commands Reference > File > FileGetSizeAndDates |
available from build: 20070905 |
This command allows the reading of the file size and dates with administrative priviledges, when needed.
call DBWShell("FileGetSizeAndDates fullPathFileName [useUTC]")
fullPathFileName |
the full path of the file |
|---|---|
useUTC |
Optional. |
When not running under DBWServer, it gets the size and dates by using the standard Win32 functionalities.
Sub Main()
DBWinit(TRUE)
DBWShell( "FileGetSizeAndDates " & replace("M:\MyArchive\MyFile.SLDDRW"," ","|"))
fileSize = DBWResult("@FILE_SIZE")
creationTime = DBWResult("@FILE_CREATION_TIME")
lastModifiedTime = DBWResult("@FILE_LAST_MODIFIED_TIME")
fileAccessTime = DBWResult("@FILE_ACCESS_TIME")
DBWMsgBox _
"size = " & fileSize & vbcrlf &_
"creation time = " & creationTime & vbcrlf &_
"last modified time = " & lastModifiedTime & vbcrlf &_
"file access time = " & fileAccessTime
End Sub