FileSavePickerUI.TrySetFileName | trySetFileName method
Tries to set the file name and extension in the file picker UI.
Syntax
var setFileNameResult = fileSavePickerUI.trySetFileName(value);
Parameters
- value
-
Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]
The file name and extension that are used to update the file name text box and file type drop-down menu in the file picker UI.
Return value
Type: SetFileNameResult
The enumeration value that indicates whether the file name and extension were updated in the file picker UI .
Remarks
As the provider of a save location, your app should call this method when the user selects a file that is displayed on your app page (which is hosted in the file picker).
This method fails if:
- The extension specified for the file in value isn't one of the allowedFileTypes.
- The file picker UI isn't visible to the user.
- The user is interacting with the file name text box in the file picker UI.
Requirements
|
Minimum supported client | Windows 8 |
|---|---|
|
Minimum supported server | Windows Server 2012 |
|
Namespace |
|
|
Metadata |
|
See also
Build date: 12/4/2012
