InternetUnicodeHTMLCSSScalable Vector Graphics (SVG)Extensible Markup Language (xml)ASP.NetDocument Object Model (DOM)JavaScript FileSystemObject ComponentFileSystemObject ObjectDrive Object Folder ObjectCopy / Delete / Move Draft for Information Only
Content
Folder Object
Folder ObjectOne key function of FileSystemObject Component is the manipulation of folders of the file system. FolderObject.CreateTextFile MethodFolderObject.CreateTextFile method for folder object is a method to return a TextStream object corresponding to the specified file after creation for text manipulation related to the specified Folder Object. Syntax:FolderObjectName.CreateTextFile(filename[,overwrite[, unicode]]) Or in VBScript. Imply Set textobjectname=FolderObjectName.CreateTextFile(filename[,overwrite[, unicode]]) Or in JScript. Imply textobjectname=FolderObjectName.CreateTextFile(filename[,overwrite[, unicode]]) Parameters:textobjectname The parameter "textobjectname" is the name assigned to the instance of the TextStream object returned by the method using the FolderObjectName.CreateTextFile Method after the specified File is created. FolderObjectName The parameter "FileSystemObjectName" is used to specify the name of the instance of the Folder Object related to. FileSystemObject object is another possible alternate object of Folder Object for the CreateTextFile Method. filename The parameter "filename" is used to specify the path relatived to the specified folder object and file name specification string of the file to be created. overwrite The optional parameter "overwrite" is a boolean value used to indicate that the existing file in destination is to be overwritten or not. The default value of parameter overwrite is false. Files are overwritten if the boolean value is true. Files are not overwritten if the boolean value is false. unicode The optional parameter "unicode" is a boolean value used to indicate that created file specified in destination is created as a Unicode or ASCII file. The default value of parameter unicode is false. File is created as a Unicode file if the boolean value is true. File is created as an ASCII file if the boolean value is false. Remarks:FolderObjectName refers to a Folder Object. And FileSystemObject object is another possible alternate object of Folder Object for the CreateTextFile Method. An error occurs if the overwrite parameter is false, or is not provided while the specified file that already exists. Examples:
FolderObject.Files CollectionFolderObject.Files collection for folder object is used to return the collection of all File objects including those files objects with hidden and system file attributes set available in the specified Folder Object. Syntax:FolderObjectName.Files Or in VBScript. Imply Set filecollectionname=FolderObjectName.Files Or in JScript. Imply filecollectionname=FolderObjectName.Files Parameters:filecollectionname The parameter "filecollectionname" is the name assigned to the instance of the Files collection returned by the Collection Property using the FolderObjectName.Files Property. FolderObjectName The parameter "FileSystemObjectName" is used to specify the name of the instance of the Folder Object related to. FileSystemObject object is another possible alternate object of Folder Object for the CreateTextFile Method. Return Values:Files collection The property returns a Collection of all available File objects related to the specified Folder Object. Properties of Collection for VBScript:
Methods of Enumerator for JScript:
Remarks:FolderObjectName refers to a Folder Object. Examples:
Files.Count Property (VBScript)Files.Count Property of FolderObject.Files Collection is a read only property used to return the number of file objects in the specified FolderObject.Files collection related to the specified folder object. Syntax:FilesCollectionName.Count Or in VBScript. Imply FilesCollectionName.Count Parameters:FilesCollectionName The parameter "FilesCollectionName" is used to specify the name of the instance of the Files Collection related to. Return Values:Number of File Objects The property returns the number of file objects included in the specified Files Collections. Files.Item Property (VBScript)Files.Item Property of FolderObject.files Collection is used to return a File object in the FolderObject.Files collection corresponding to the specified key in the specified Folder.Files collection related to the specified Folder object. Syntax:FilesCollectionName.Item(key) Or in VBScript. Imply FilesCollectionName.Item(key) Parameters:FilesCollectionName The parameter "FilesCollectionName" is used to specify the name of the instance of the Files Collection related to. Return Values:File Object The property returns a File object corresponding to the specified key in the specified Files Collection. Examples:
FilesEnum.atEnd MethodFilesEnum.atEnd Method of the Enumerator of FolderObject.Files 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 Folder.Files collection related to the specified Folder object. Syntax:FilesEnumName.atEnd Or in JScript. Imply FilesEnumName.atEnd Parameters:FilesEnumName The parameter "FilesEnumName" is used to specify the name of the instance of the Files 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 folderObject.files 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. FilesEnum.item MethodFilesEnum.item Method of the Enumerator of FolderObject.Files Collection is used to return the current item of the File object in the specified enumerator of the Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. Syntax:FilesEnumName.item Or in JScript. Imply FilesEnumName.item Parameters:FilesEnumName The parameter "FilesEnumName" is used to specify the name of the instance of the Files Enumerator related to. Return Values:File object The method returns the current item of the File object in the specified enumerator of the Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. The return values is "undefined" if the enumerator of the collection is empty or the current item is undefined. FilesEnum.moveFirst MethodFilesEnum.moveFirst Method of the Enumerator of FolderObject.Files Collection is used to reset the location of the current item of the File object to the first item in the specified enumerator of the Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. Syntax:FilesEnumName.moveFirst Or in JScript. Imply FilesEnumName.moveFirst Parameters:FilesEnumName The parameter "FilesEnumName" is used to specify the name of the instance of the Files 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 Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. If there is no item in the collection, the current item is set to undefined. FilesEnum.moveNext MethodFilesEnum.moveNext Method of the Enumerator of FolderObject.Files Collection is used to move the location of the current item of the File object to the next item in the specified enumerator of the Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. Syntax:FilesEnumName.moveNext Or in JScript. Imply FilesEnumName.moveNext Parameters:FilesEnumName The parameter "FilesEnumName" is used to specify the name of the instance of the Files Enumerator related to. Remarks:The method move the location of the current item of the specified enumerator to the next item of the specified enumerator of the Files collection corresponding to the specified FolderObject.Files Collection related to the specified Folder object. If there is no item or no more item in the collection, the current item is set to undefined. Examples:
FolderObject.ParentFolder PropertyFolderObject.ParentFolder property for folder object is a read-only property to return a folder object corresponding to the parent folder of the specified Folder Object. Syntax:FolderObjectName.PartentFolder Or in VBScript. Imply Set parentfoldername=FolderObjectName.PartentFolder Or in JScript. Imply parentfoldername=FolderObjectName.PartentFolder Parameters:parentfoldername The parameter "parentfoldername" is the name assigned to the instance of the Folder object returned by the property using the FolderObjectName.ParentFolder property related to the specified Folder object. FolderObjectName The parameter "FolderObjectName" is used to specify the name of the instance of the Folder Object related to. File object is another possible alternate object of Folder Object for the ParentFolder property. Remarks:FolderObjectName refers to a Folder Object. And File object is another possible alternate object of Folder Object for the ParentFolder Property. Examples:
FolderObject.SubFolders CollectionFolderObject.SubFolders collection for folder object is used to return the collection of all subfolders objects including those files objects with hidden and system file attributes set available in the specified Folder Object. Syntax:FolderObjectName.SubFolders Or in VBScript. Imply Set foldercollectionname=FolderObjectName.Folders Or in JScript. Imply foldercollectionname=FolderObjectName.Folders Parameters:foldercollectionname The parameter "foldercollectionname" is the name assigned to the instance of the Folders collection returned by the Collection Property using the FolderObjectName.Folders Property. FolderObjectName The parameter "FileSystemObjectName" is used to specify the name of the instance of the Folder Object related to. FileSystemObject object is another possible alternate object of Folder Object for the CreateTextFile Method. Return Values:Folders collection The property returns a Collection of all available sub-Folder objects contained in the specified Folder Object. Properties of Collection for VBScript:
Methods of Enumerator for JScript:
Remarks:FolderObjectName refers to a Folder Object. The ActiveXObject object (JScript) and CreateObject function (VBScript) enable and return a reference to an Automation object. Examples:
Folders.Count Property (VBScript)Folders.Count Property of FolderObject.SubFolders Collection is a read only property used to return the number of file objects in the specified FolderObject.SubFolders collection related to the specified folder object. Syntax::FoldersCollectionName.Count Or in VBScript. Implyy FoldersCollectionName.Count Parameters::FoldersCollectionName The parameter "FoldersCollectionName" is used to specify the name of the instance of the Folders Collection related to. Return Values::Number of Folder Objects The property returns the number of sub folder objects included in the specified Folders Collections. Folders.Item Property (VBScript)Folders.Item Property of FolderObject.Subfolders Collection is used to return a Folder object in the FolderObject.SubFolders collection corresponding to the specified key in the specified Folder.SubFolders collection related to the specified Folder object. Syntax::FoldersCollectionName.Item(key) Or in VBScript. Implyy FoldersCollectionName.Item(key) Parameters::FoldersCollectionName The parameter "FoldersCollectionName" is used to specify the name of the instance of the Folders Collection related to. Return Values::Folder Object The property returns a Folder object corresponding to the specified key in the specified Folders Collection. Examples::
FoldersEnum.atEnd MethodFoldersEnum.atEnd Method of the Enumerator of FolderObject.SubFolders 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 Folder.SubFolders collection related to the specified Folder object. Syntax:SubFoldersEnumName.atEnd Or in JScript. Imply SubFoldersEnumName.atEnd Parameters:SubFoldersEnumName The parameter "SubFoldersEnumName" is used to specify the name of the instance of the Folders 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 folderObject.subfolders 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. FoldersEnum.item MethodFoldersEnum.item Method of the Enumerator of FolderObject.subFolders Collection is used to return the current item of the Folder object in the specified enumerator of the SubFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. Syntax:SubFoldersEnumName.item Or in JScript. Implyy SubFoldersEnumName.item Parameters::FilesEnumName The parameter "SubFoldersEnumName" is used to specify the name of the instance of the Folders Enumerator related to. Return Values::Folder object The method returns the current item of the Folder object in the specified enumerator of the subFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. The return values is "undefined" if the enumerator of the collection is empty or the current item is undefined. FoldersEnum.moveFirst MethodFoldersEnum.moveFirst Method of the Enumerator of FolderObject.SubFolders Collection is used to reset the location of the current item of the Folder object to the first item in the specified enumerator of the SubFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. Syntax:SubFoldersEnumName.moveFirst Or in JScript. Imply SubFoldersEnumName.moveFirst Parameters:SubFoldersEnumName The parameter "SubFoldersEnumName" is used to specify the name of the instance of the SubFolders 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 SubFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. If there is no item in the collection, the current item is set to undefined. FoldersEnum.moveNext MethodFoldersEnum.moveNext Method of the Enumerator of FolderObject.SubFolders Collection is used to move the location of the current item of the Folder object to the next item in the specified enumerator of the SubFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. Syntax:SubFoldersEnumName.moveNext Or in JScript. Implyly SubFoldersEnumName.moveNext Parameters:SubFoldersEnumName The parameter "SubFoldersEnumName" is used to specify the name of the instance of the SubFolders Enumerator related to. Remarks:s:The method move the location of the current item of the specified enumerator to the next item of the specified enumerator of the SubFolders collection corresponding to the specified FolderObject.SubFolders Collection related to the specified Folder object. If there is no item or no more item in the collection, the current item is set to undefined. Examples:s:
©sideway ID: 130500008 Last Updated: 5/11/2013 Revision: 0 Ref: References
Latest Updated Links
|
Home 5 Business Management HBR 3 Information Recreation Hobbies 8 Culture Chinese 1097 English 339 Travel 7 Reference 79 Computer Hardware 251 Software Application 213 Digitization 32 Latex 52 Manim 205 KB 1 Numeric 19 Programming Web 289 Unicode 504 HTML 66 CSS 65 SVG 46 ASP.NET 270 OS 431 DeskTop 7 Python 72 Knowledge Mathematics Formulas 8 Set 1 Logic 1 Algebra 84 Number Theory 206 Trigonometry 31 Geometry 34 Calculus 67 Engineering Tables 8 Mechanical Rigid Bodies Statics 92 Dynamics 37 Fluid 5 Control Acoustics 19 Natural Sciences Matter 1 Electric 27 Biology 1 |
Copyright © 2000-2024 Sideway . All rights reserved Disclaimers last modified on 06 September 2019