Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSSavePanelMBS class.

NSSavePanelMBS.accessoryView as NSViewMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The custom accessory view for the current application.

You can place any Cocoa control on that panel.
(Read and Write property)

NSSavePanelMBS.allowsOtherFileTypes as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A Boolean value that indicates whether the receiver allows the user to save files with an extension that's not in the list of allowed types.

If the user tries to save a filename with a recognized extension that's not in the list of allowed types they are presented with a dialog. If this property is true, then the dialog presents the option of using the extension the user specified.

The default setting is false.
(Read and Write property)

Some examples using this property:

NSSavePanelMBS.canCreateDirectories as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the receiver allows the user to create directories.

(Read and Write property)

Some examples using this property:

NSSavePanelMBS.canSelectHiddenExtension as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A Boolean value that indicates whether the receiver allows the user to hide or show extensions.

(Read and Write property)

Some examples using this property:

NSSavePanelMBS.Directory as folderitem

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The path of the directory currently shown in the panel.

May be nil on any error.
(Read and Write property)

NSSavePanelMBS.directoryURL as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 9.6 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The directory shown in the panel as a URL.

Available in Mac OS X v10.6 and later.
(Read and Write property)

NSSavePanelMBS.isExpanded as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the panel is expanded.

(Read only property)

NSSavePanelMBS.isExtensionHidden as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether the extension-hiding checkbox is visible and checked.

True to show the checkbox and false to hide.
(Read and Write property)

NSSavePanelMBS.Message as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The message displayed in the panel.

The default message text is an empty string.
(Read and Write property)

NSSavePanelMBS.NameFieldLabel as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The string displayed in front of the filename text field.

By default the label is "Save As:".
(Read and Write property)

Some examples using this property:

NSSavePanelMBS.nameFieldStringValue as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 9.6 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The user-editable filename currently shown in the name field.

Available in Mac OS X v10.6 and later.
(Read and Write property)

Some examples using this property:

NSSavePanelMBS.Prompt as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The prompt of the default button.

This prompt appears on all SavePanel objects (or all OpenPanel objects if the panel of this message is an NSOpenPanel instance) in your application. By default the text in the default button is "Open" for an Open panel and "Save" for a Save panel.

It is intended that short words or phrases, such as "Open", "Save", "Set", or "Choose", be used on the button. The button is not resized to accommodate long prompts.

Since this method previously affected a title field, any colon at the end of prompt is removed.
(Read and Write property)

NSSavePanelMBS.requiredFileType as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The required file type (if any).

A file specified in the Save panel is saved with the designated filename and this file type as an extension. Examples of common file types are "rtf", "tiff", and "ps". File type strings encoding HFS file types are not valid values for this attribute. An "" return value indicates that the user can save to any ASCII file.

This method is equivalent to calling allowedFileTypes and returning the first element of the list of allowed types, or "" if there are none.
(Read and Write property)

NSSavePanelMBS.showsHiddenFiles as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 8.2 ✅ Yes ❌ No ❌ No ❌ No Desktop only
Whether to show or hide the invisible files.

This is a function using undocumented features from the Apple NSSavePanel class, so there is not guarantee that it will work in future versions.
(Read and Write property)

Some examples using this property:

NSSavePanelMBS.showsTagField as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 23.0 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A Boolean value that indicates whether the panel displays the Tags field.
Example

dim n as new NSSavePanelMBS
n.showsTagField = true
n.setTagNames array("test")

When the value of this property is true, the panel displays the Tags field; if NO, the panel doesn’t display the Tags field. The default value is true. (Note that the Tags field is appropriate only in a Save panel.)
If you set this property to true, you are responsible for setting tag names on the resulting file after saving is complete. If you don’t set this property, macOS will automatically show the tag field and attempt to apply the tags to the file. To set tags on files, use the NSURLTagNamesKey.
(Read and Write property)

NSSavePanelMBS.Title as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
The title of the panel.

(Read and Write property)

NSSavePanelMBS.treatsFilePackagesAsDirectories as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Navigation MBS MacCocoa Plugin 7.8 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A Boolean value that indicates whether the panel displays file packages to the user as directories.

(Read and Write property)

Some examples using this property:

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


The biggest plugin in space...