IsolatedStorageFile.MoveFile(String, String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Moves a specified file to a new location, and optionally lets you specify a new file name.
public:
void MoveFile(System::String ^ sourceFileName, System::String ^ destinationFileName);
public void MoveFile (string sourceFileName, string destinationFileName);
[System.Runtime.InteropServices.ComVisible(false)]
public void MoveFile (string sourceFileName, string destinationFileName);
member this.MoveFile : string * string -> unit
[<System.Runtime.InteropServices.ComVisible(false)>]
member this.MoveFile : string * string -> unit
Public Sub MoveFile (sourceFileName As String, destinationFileName As String)
Parameters
- sourceFileName
- String
The name of the file to move.
- destinationFileName
- String
The path to the new location for the file. If a file name is included, the moved file will have that name.
- Attributes
Exceptions
sourceFileName
or destinationFileName
is a zero-length string, contains only white space, or contains one or more invalid characters defined by the GetInvalidPathChars() method.
sourceFileName
or destinationFileName
is null
.
The isolated store has been closed.
The isolated store has been disposed.
sourceFileName
was not found.
Remarks
This method does not throw an exception if sourceFileName
and destinationFileName
are the same.