11.07.2015 Views

VBScript Reference Manual for InduSoft Web Studio - ICP DAS

VBScript Reference Manual for InduSoft Web Studio - ICP DAS

VBScript Reference Manual for InduSoft Web Studio - ICP DAS

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>InduSoft</strong> <strong>Web</strong> <strong>Studio</strong><strong>VBScript</strong> <strong>Reference</strong> <strong>Manual</strong>File ObjectThe File object provides access to all the properties of a file.File Object MethodsPropertiesCopyDeleteMoveOpenAsTextStreamDescriptionCopies a file from one location to another.Deletes a file.Moves a file from one location to another.Opens a file and returns a TextStream object.File Object PropertiesPropertiesDescriptionAttributesThe attributes of a file.DateCreated The date and time that the file was created.DateLastAccessed The date and time that the file was last accessed.DateLastModified The date and time that the file was last modified.DriveThe drive letter of the drive on which the file resides.NameThe name of the file.ParentFolder The Folder object <strong>for</strong> the parent of the file.PathThe file system path to the file.ShortName The short name used by programs that require 8.3 names.ShortPathThe short path use by programs that require 8.3 names.SizeThe size, in bytes, of a file.TypeIn<strong>for</strong>mation about the type of a file.The following code illustrates how to obtain a File object and how to view one of its properties.Sub ShowFileInfo(filespec)Dim fs, f, sSet fs = CreateObject("Scripting.FileSystemObject")Set f = fs.GetFile(filespec)s = f.DateCreatedResponse.Write sEnd Sub<strong>InduSoft</strong>, Ltd. 33

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!