Platforms to show: All Mac Windows Linux Cross-Platform

MacMountServerVolumeMBS(URL as string, MountDir as String, User as String, Password as String, byref Disk as FolderItem, flags as Integer) as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
global method System MBS MacOSX Plugin 16.1 ✅ Yes ❌ No ❌ No ✅ Yes All
This routine will mount the server specified by url at mountDir (or the default location if mountDir is empty).
Example
dim flags as Integer = 0
dim disk as FolderItem
dim URL as string = "smb://Test.local"
dim user as string = "root"
dim pass as string = "xxx"

dim e as Integer = MacMountServerVolumeMBS(URL, "", user, pass, disk, flags)

if e = 0 then
MsgBox "OK"
else
MsgBox disk.NativePath
end if

An optional user and password can be passed in for authentication. If no user or password is provided then the underlying file system will handle authentication if required. This routine returns after the mount is complete.

url: The server to mount.
mountDir: The directory to mount the server to (default if empty).
user: String to pass as user for authentication.
password: String to pass as password for authenticated log in.
Disk: The folderItem of the newly mounted volume.
Flags: Options (such as kFSMountServerMarkDoNotDisplay and kFSMountServerMountOnMountDir).

ConstantValueDescription
kFSMountServerMarkDoNotDisplay1Specify this option if you do want the volume displayed as a stand
along volume in the UI.
kFSMountServerMountOnMountDir4Specify this option if you want the volume mounted on the mountdir passed in instead of in it.
kFSMountServerSuppressConnectionUI&h40Specify this option if you want to suppress connection-time UI when mounting the server volume.

Returns Mac OS X error code. Zero for success.

Blog Entries

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


The biggest plugin in space...