MDirectoryEntry

From HTML5 Builder
Jump to: navigation, search

MDirectoryEntry is a directory on device’s file system.

Functions

These are JavaScript functions you can call when you use this component in a screen.
Note: Replace ComponentName with the actual name of the component, that is, the value of its Name property. For example: MDirectoryEntry1.
ComponentNameGetMetadata
Looks up metadata about directory. It triggers OnGetMetadata event, or OnGetMetadataError if an error occurs.
ComponentNameMoveTo
Move directory to a new location. When you call it, pass it the location of directory’s new parent folder, and (optionally) directory’s new name. It triggers OnMoveTo event, or OnMoveToError if an error occurs.
ComponentNameCopyTo
Copy directory somewhere. When you call it, pass it the location of directory’s new copy parent folder, and (optionally) directory’s new copy name. It triggers OnCopyTo event, or OnCopyToError if an error occurs.
ComponentNameRemove
Removes directory, which must be empty. It triggers OnRemove event, or OnRemoveError if an error occurs.
ComponentNameGetParent
Gets a DirectoryEntry object for directory’s parent directory. It triggers OnGetParent event, or OnGetParentError if an error occurs.
ComponentNameGetDirectory
Returns a DirectoryEntry object for passed path, which can be relative to ComponentName. It triggers OnGetDirectory event, or OnGetDirectoryError if an error occurs.
ComponentNameGetFile
Returns a FileEntry object for passed path, which can be relative to ComponentName. It triggers OnGetFile event, or OnGetFileError if an error occurs.
ComponentNameRemoveRecursively
Remove directory and all its content, if any. It triggers OnRemoveRecursively event, or OnRemoveRecursivelyError if an error occurs.

Events

These are JavaScript MDirectoryEntry events you can associate to JavaScript functions.

OnCopyTo
This event gets triggered when ComponentNameCopyTo successfully copies the directory to a new location.
OnCopyToError
This event gets triggered when an error occurs after calling ComponentNameCopyTo. Its only parameter is a ContactError object.
OnGetDirectory
This event gets triggered when ComponentNameGetDirectory successfully returns a DirectoryEntry object.
OnGetDirectoryError
This event gets triggered when an error occurs after calling ComponentNameGetDirectory. Its only parameter is a ContactError object.
OnGetFile
This event gets triggered when ComponentNameGetFile successfully returns a FileEntry object.
OnGetFileError
This event gets triggered when an error occurs after calling ComponentNameGetFile. Its only parameter is a ContactError object.
OnGetMetadata
This event gets triggered when ComponentNameGetMetadata successfully returns a Metadata object, which is its only parameter.
OnGetMetadataError
This event gets triggered when an error occurs after calling ComponentNameGetMetadata. Its only parameter is a ContactError object.
OnGetParent
This event gets triggered when ComponentNameGetParent successfully returns a DirectoryEntry object, which is its only parameter.
OnGetParentError
This event gets triggered when an error occurs after calling ComponentNameGetParent. Its only parameter is a ContactError object.
OnMoveTo
This event gets triggered when ComponentNameMoveTo successfully moves the directory to its new location.
OnMoveToError
This event gets triggered when an error occurs after calling ComponentNameMoveTo. Its only parameter is a ContactError object.
OnRemove
This event gets triggered when ComponentNameRemove successfully removes the empty directory.
OnRemoveError
This event gets triggered when an error occurs after calling ComponentNameRemove. Its only parameter is a ContactError object.
OnRemoveRecursively
This event gets triggered when ComponentNameRemoveRecursively successfully removes the directory and all its content.
OnRemoveRecursivelyError
This event gets triggered when an error occurs after calling ComponentNameRemoveRecursively. Its only parameter is a ContactError object.

See Also

Personal tools