Link:http://output.to/sideway/default.asp?qno=130300019 TextStream Object, FileSystemObject Component, ASP Server Component TextStream ObjectTextStream object of FileSystemObject component is related to manipulating the contents of a text file sequentially. Unlike other object in the FileSystemObject component, the TextSteam object returned from the FileSystemObject object provides an intermediate variable placeholder as the representation of the contents of the sequential text stream of the text file for manipulation. Methods
Properties
RemarksThe methods and properties of TextStream object can be grouped into
Link:http://output.to/sideway/default.asp?qno=130300020 GetSpecialFolder, Drives, FileSystemObject Object, ASP Server Component, Built-in Function FileSystemObject ObjectOne function of FileSystemObject object is the manipulation of general file system information. One type of the file system manipulation is related to the local system. The other type of the file system manipulation is related to the path string editing and the path string need not be an existing path. FileSystemObject.GetSpecialFolder MethodFileSystemObject.GetSpecialFolder method is the method to return an instance of a Folder object corresponding to the specified special folder specification related to the specified FileSystemObject Object.. Syntax:FileSystemObjectName.GetSpecialFolder(folderspec) Or in VBScript. Imply Set FolderObjectName = FileSystemObjectName.GetSpecialFolder(folderspec) Or in JScript. Imply FolderObjectName = FileSystemObjectName.GetSpecialFolder(folderspec) Parameters:FolderObjectName The parameter "FolderObjectName" is the name assigned to the instance of the Folder object created by the method using the FileSystemObjectName.GetSpecialFolder Method. FileSystemObjectName The parameter "FileSystemObjectName" is used to specify the name of the instance of the FileSystemObject Object related to. folderspec The parameter "folderspec" is used to specify the name of the special folder to be returned. The value of parameter "folderspec" can be
Return Values:Folder object The method returns a Folder object of the special system folder corresponding to the specified folderspec related to the specified FileSystemObject Object. Remarks:FileSystemObjectName should always refer to a FileSystemObject Object Examples:
FileSystemObject.Drives CollectionFileSystemObject.Drives Collection is used to return the collection of all Drive objects available on the file system of the local machine related to the specified FileSystemObject Object. Syntax:FileSystemObjectName.Drives Or in VBScript. Imply Set DrivesCollectionName = FileSystemObjectName.Drives Or in JScript. Imply DrivesCollectionName = new Enumerator(FileSystemObjectName.Drives) Parameters:DrivesCollectionName The parameter "DrivesCollectionName" is the name assigned to the instance of the Drives collection returned by the Collection Property using the FileSystemObjectName.Drives Property. FileSystemObjectName The parameter "FileSystemObjectName" is used to specify the name of the instance of the FileSystemObject Object related to. Return Values:Drives collection The property returns a Collection of all available Drive objects related to the specified FileSystemObject Object. Remarks:FileSystemObjectName should always refer to a FileSystemObject Object. Properties of Collection for VBScript:
Methods of Enumerator for JScript:
Remarks:FileSystemObjectName should always refer to a FileSystemObject Object. The term "Drive" under the FSO model can be a hard disk, a CD-Rom drive, a RAM disk or logically connected network Drive etc. For removable-media drives, the media is not necessary to be inserted into the removable-media drives before these removable-media drives can be appeared in the Drives collection. For JScript, the Collection is packed as an Enumerator at which Count property is not supported. And the supported properties are atEnd() method, item method, moveFirst method, and moveNext Method. Examples:
Drives.Count Property (VBScript)Drives.Count Property of FileSystemObject.Drives Collection is a read only property used to return the number of drive objects in the specified FileSystemObject.Drives collection related to the specified FileSystemObject object. Syntax:DrivesCollectionName.Count Or in VBScript. Imply DrivesCollectionName.Count Parameters:FileSystemObjectName The parameter "DrivesCollectionName" is used to specify the name of the instance of the Drives Collection related to. Return Values:Number of Drive Objects The property returns the number of drive objects included in the specified Drives Collections. Drives.Item Property (VBScript)Drives.Item Property of FileSystemObject.Drives Collection is used to return a Drive object in the FileSystemObject.Drives collection corresponding to the specified key in the specified FileSystemObject.Drives collection related to the specified FileSystemObject object. Syntax:DrivesCollectionName.Item(key) Or in VBScript. Imply DrivesCollectionName.Item(key) Parameters:FileSystemObjectName The parameter "DrivesCollectionName" is used to specify the name of the instance of the Drives Collection related to. Return Values:Drive Object The property returns a drive object corresponding to the specified key in the specified Drives Collection. Examples:
DrivesEnum.atEnd MethodDrivesEnum.atEnd Method of the Enumerator of FileSystemObject.Drives Collection is used to check whether the enumerator is at the end of the colloection and returns a Boolean true value to indicate the Enumerator is at the end of the enumerator of the specified FileSystemObject.Drives collection related to the specified FileSystemObject object. Syntax:DrivesEnumName.atEnd Or in JScript. Imply DrivesEnumName.atEnd Parameters:DrivesEnumName The parameter "DrivesEnumName" is used to specify the name of the instance of the Drives Enumerator related to. Return Values:Boolean The method returns a Boolean true value to indicate the specified enumerator is at the end of the enumerator of the specified FileSystemObject.Drives collection. A Boolean false value indicates that the specified enumerator is not at the end of the enumerator or the enumerator of the collection is empty. DrivesEnum.item MethodDrivesEnum.item Method of the Enumerator of FileSystemObject.Drives Collection is used to return the current item of the Drive object in the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. Syntax:DrivesEnumName.item Or in JScript. Imply DrivesEnumName.item Parameters:DrivesEnumName The parameter "DrivesEnumName" is used to specify the name of the instance of the Drives Enumerator related to. Return Values:Drive object The method returns the current item of the Drive object in the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. The return values is "undefined" if the enumerator of the collection is empty or the current item is undefined. DrivesEnum.moveFirst MethodDrivesEnum.moveFirst Method of the Enumerator of FileSystemObject.Drives Collection is used to reset the location of the current item of the Drive object to the first item in the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. Syntax:DrivesEnumName.moveFirst Or in JScript. Imply DrivesEnumName.moveFirst Parameters:DrivesEnumName The parameter "DrivesEnumName" is used to specify the name of the instance of the Drives Enumerator related to. Remarks:The method reset the location of the current item of the specified enumerator to the first item of the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. If there is no item in the collection, the current item is set to undefined. DrivesEnum.moveNext MethodDrivesEnum.moveNext Method of the Enumerator of FileSystemObject.Drives Collection is used to move the location of the current item of the Drive object to the next item in the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. Syntax:DrivesEnumName.moveNext Or in JScript. Imply DrivesEnumName.moveNext Parameters:DrivesEnumName The parameter "DrivesEnumName" is used to specify the name of the instance of the Drives Enumerator related to. Remarks:The method movet the location of the current item of the specified enumerator to the next item of the specified enumerator of the Drives collection corresponding to the specified FileSystemObject.Drives Collection related to the specified FileSystemObject object. If there is no item or no more item in the collection, the current item is set to undefined. Examples:
Link:http://output.to/sideway/default.asp?qno=130300018 ASP Server Component, Built-in Function, File Object File ObjectFile object of FileSystemObject component is related to manipulating file of a file system of the web server located. Methods
Properties
RemarksThe methods and properties of File object can be grouped into
|
Sideway BICK Blog 16/03 |