GDStorageFileExportFromSecureStorageAsync Method (IStorageFolder, String) |
Namespace: GD
public IAsyncOperation<StorageFile> ExportFromSecureStorageAsync( IStorageFolder destinationFolder, string desiredNewName )
Exception | Condition |
---|---|
Exception | A file with the specified desiredName already exists in the destinationFolder or some unexpected error occurred. |
AccessDeniedException | Secure storage was remotely wiped or you don't have permission to create a file in the current folder. |
InvalidArgumentException | The format of the filename is incorrect. Check the value of desiredName. |
This method uses the FailIfExists value from the NameCollisionOption enumeration by default. That is, this method raises an exception if a file with the same name already exists in the destination folder. If you want to handle a file name collision in a different way, call the ExportFromSecureStorageAsync(IStorageFolder, String, NameCollisionOption) method.
Note: Windows file system is case-insensitive, but BlackBerry Dynamics Secure Storage is case-sensitive. That means that exporting two separate GDStorageFiles to the same destinationFolder can cause a name collision (e.g. "Test.txt" and "tets.txt")
GDStorageFile after export isn't deleted.