Platforms to show: All Mac Windows Linux Cross-Platform

Back to WinFileDialogMBS class.

WinFileDialogMBS.ClientGuid as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The client GUID.

A dialog's state can include factors such as the last visited folder and the position and size of the dialog.
Typically, this state is persisted based on the name of the executable file. By specifying a GUID, an application can have different persisted states for different versions of the dialog within the same application (for example, an import dialog and an open dialog).

SetClientGuid should be called immediately after creation of the dialog object.

Enables a calling application to associate a GUID with a dialog's persisted state.
(Read and Write property)

WinFileDialogMBS.CurrentSelection as WinShellItemMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The user's current selection in the dialog.

The item currently selected in the dialog. This item can be a file or folder selected in the view window, or something that the user has entered into the dialog's edit box. The latter case may require a parsing operation (cancelable by the user) that blocks the current thread.

If not result exists, the plugin returns nil and raises no failed exceptions.
(Read only property)

WinFileDialogMBS.DefaultExtension as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The default extension to be added to file names.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.DefaultExtension = "jpg"

The extension text. This string should not include a leading period. For example, "jpg" is correct, while ".jpg" is not.

If this method is called before showing the dialog, the dialog will update the default extension automatically when the user chooses a new file type (see SetFileTypes).
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.DefaultFolder as WinShellItemMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The folder used as a default if there is not a recently used folder value available.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.DefaultFolder = New WinShellItemMBS(SpecialFolder.Desktop)

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.FileName as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The text currently entered in the dialog's File name edit box.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.FileName = "New Document"

The text in the File name edit box does not necessarily reflect the item the user chose. To get the item the user chose, use Result property.

If not result exists, the plugin returns "" and raises no failed exceptions.
(Read and Write property)

WinFileDialogMBS.FileNameLabel as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The text of the label next to the file name edit box.

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.FileTypeIndex as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The currently selected file type.

The index of the selected file type in the file type array passed to SetFileTypes.

This is a one-based index rather than zero-based.
FileTypeIndex can be called either while the dialog is open or after it has closed.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.Folder as WinShellItemMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
A folder that is always selected when the dialog is opened, regardless of previous user action.

Gets either the folder currently selected in the dialog, or, if the dialog is not currently displayed, the folder that is to be selected when the dialog is opened.

This folder overrides any "most recently used" folder. If this method is called while the dialog is displayed, it causes the dialog to navigate to the specified folder.
In general, we do not recommended the use of this method. If you call SetFolder before you display the dialog box, the most recent location that the user saved to or opened from is not shown. Unless there is a very specific reason for this behavior, it is not a good or expected user experience and should therefore be avoided. In almost all instances, SetDefaultFolder is the better method.

As of Windows 7, if the path of the folder specified through psi is the default path of a known folder, the known folder's current path is used in the dialog. That path might not be the same as the path specified in psi; for instance, if the known folder has been redirected. If the known folder is a library (virtual folders Documents, Music, Pictures, and Videos), the library's path is used in the dialog. If the specified library is hidden (as they are by default as of Windows 8.1), the library's default save location is used in the dialog, such as the Microsoft OneDrive Documents folder for the Documents library. Because of these mappings, the folder location used in the dialog might not be exactly as you specified when you called this method.
(Read and Write property)

WinFileDialogMBS.Handle as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The internal object reference.

(Read and Write property)

WinFileDialogMBS.OkButtonLabel as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The text of the Open or Save button.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OkButtonLabel = "Export"

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionAllNonStorageItems as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Enables the user to choose any item in the Shell namespace, not just those with SFGAO_STREAM or SFAGO_FILESYSTEM attributes. #

This flag cannot be combined with OptionForceFileSystem.
(Read and Write property)

WinFileDialogMBS.OptionAllowMultiSelect as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Enables the user to select multiple items in the open dialog.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionAllowMultiSelect = true

Note that when this flag is set, the WinFileOpenDialogMBS class must be used to retrieve those items.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionCreatePrompt as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Prompt for creation if the item returned in the save dialog does not exist.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionCreatePrompt = true

Note that this does not actually create the item.
(Read and Write property)

WinFileDialogMBS.OptionDefaultNoMiniMode as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Indicates to the Save As dialog box that it should open in expanded mode.

Expanded mode is the mode that is set and unset by clicking the button in the lower-left corner of the Save As dialog box that switches between Browse Folders and Hide Folders when clicked. This value is not supported as of Windows 7.
(Read and Write property)

WinFileDialogMBS.OptionDontAaddToRecent as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Do not add the item being opened or saved to the recent documents list.

(Read and Write property)

WinFileDialogMBS.OptionFileMustExist as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The item returned must exist.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionFileMustExist = true

This is a default value for the Open dialog.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionForceFileSystem as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Ensures that returned items are file system items.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionForceFileSystem = true

Note that this does not apply to items returned by CurrentSelection.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionForcePreviewPaneOn as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Indicates to the Open dialog box that the preview pane should always be displayed.

(Read and Write property)

WinFileDialogMBS.OptionForceShowHidden as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Include hidden and system items.

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionHideMRUPlaces as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Hide the list of places from which the user has recently opened or saved items. This value is not supported as of Windows 7.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionHideMRUPlaces = true

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionHidePinnedPlaces as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Hide items shown by default in the view's navigation pane.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionHidePinnedPlaces = true

This flag is often used in conjunction with the AddPlace method, to hide standard locations and replace them with custom locations.

Windows 7 and later. Hide all of the standard namespace locations (such as Favorites, Libraries, Computer, and Network) shown in the navigation pane.

Windows Vista. Hide the contents of the Favorite Links tree in the navigation pane. Note that the category itself is still displayed, but shown as empty.
(Read and Write property)

WinFileDialogMBS.OptionNoChangeDir as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Don't change the current working directory.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionNoChangeDir = true

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionNoDereferenceLinks as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Shortcuts should not be treated as their target items.

This allows an application to open a .lnk file rather than what that file is a shortcut to.
(Read and Write property)

WinFileDialogMBS.OptionNoReadOnlyReturn as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Do not return read-only items.

This is a default value for the Save dialog.
(Read and Write property)

WinFileDialogMBS.OptionNoTestFileCreate as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Do not test whether creation of the item as specified in the Save dialog will be successful.

If this flag is not set, the calling application must handle errors, such as denial of access, discovered when the item is created.
(Read and Write property)

WinFileDialogMBS.OptionNoValidate as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Do not check for situations that would prevent an application from opening the selected file, such as sharing violations or access denied errors.

(Read and Write property)

WinFileDialogMBS.OptionOKButtonNeedsInteraction as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
OKButton needs interaction?

(Read and Write property)

WinFileDialogMBS.OptionOverwritePrompt as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
When saving a file, prompt before overwriting an existing file of the same name.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionOverwritePrompt = true

This is a default value for the Save dialog.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionPathMustExist as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The item returned must be in an existing folder.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.OptionPathMustExist = true

This is a default value.
(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionPickFolders as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Present an Open dialog that offers a choice of folders rather than files.

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.Options as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The current flags that are set to control dialog behavior.

See kOptions* constants.

Generally, you should read the property, modify it to include or exclude options by setting the appropriate flags and assign it again.
(Read and Write property)

WinFileDialogMBS.OptionShareaware as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
In the case of a sharing violation when an application is opening a file, call the application back through ShareViolation event for guidance.

This flag is overridden by kOptionsNoValidate.
(Read and Write property)

WinFileDialogMBS.OptionStrictFileTypes as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
In the Save dialog, only allow the user to choose a file that has one of the file name extensions specified through SetFileTypes.

(Read and Write property)

Some examples using this property:

WinFileDialogMBS.OptionSupportsStreamableItems as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Indicates that the caller is opening a file as a stream (BHID_Stream), so there is no need to download that file.

(Read and Write property)

WinFileDialogMBS.ProminentControlID as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Places a control in the dialog so that it stands out compared to other added controls.

Setting this property causes the control to be placed near the Open or Save button instead of being grouped with the rest of the custom controls.
Only check buttons (check boxes), push buttons, combo boxes, and menus—or a visual group that contains only a single item of one of those types—can be made prominent.
Only one control can be marked in this way. If a dialog has only one added control, that control is marked as prominent by default.
(Read and Write property)

WinFileDialogMBS.Result as WinShellItemMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The choice that the user made in the dialog.

Result can be called after the dialog has closed or during the handling of an OnFileOk event. Calling this method at any other time will fail. If multiple items were chosen, this method will fail. In the case of multiple items, call Results method.
Show must return a success code for a result to be available to Result.

If not result exists, the plugin returns nil and raises no failed exceptions.
(Read only property)

WinFileDialogMBS.Title as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
The title of the dialog.
Example
Dim d As WinFileOpenDialogMBS // your dialog
d.title = "Export database"

(Read and Write property)

WinFileDialogMBS.WindowHandle as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS WinFrameworks Plugin 20.1 ❌ No ✅ Yes ❌ No ❌ No Desktop only
Queries window handle.

Value is a HWND and may be used in declares.
(Read only property)

The items on this page are in the following plugins: MBS WinFrameworks Plugin.


The biggest plugin in space...