DartStream Object : FileName Property |
Visual Basic |
---|
Public Property FileName As String |
When set to a file name, the file is opened. When set to an empty string, the file is closed.
When set to an empty string and then changed to a file name, a file is created or opened according to FileMode. If an existing file is opened, the value of the Size property determines how the file is treated:
When set to a file name and then changed to an empty string, all data in the file is buffered to memory and the file is closed.
When set to a file name and then changed to a different file name, the file is moved to the new location. If FileMode = createUnique, an existing file cannot be unintentionally overwritten.
You can delete a file only by setting this property to an existing file name, setting FileMode to createOpen or createExisting, setting DeleteOnDestroy to True, and allowing the DartStream Object to be destroyed.