Platforms to show: All Mac Windows Linux Cross-Platform

Back to SystemConfigurationMBS class.

SystemConfigurationMBS.ComputerName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the current computer name.
Example
dim s as new SystemConfigurationMBS
msgbox s.ComputerName

Returns "" on an error.

SystemConfigurationMBS.ComputerNameEncoding as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
The encoding of the computer name.

Some examples using this method:

SystemConfigurationMBS.ConsoleUser as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the name of the currently logged-in user.
Example
dim s as new SystemConfigurationMBS
msgbox s.ConsoleUser

Returns the user currently logged into the system; "" if no user is logged in or if an error was encountered.

Some examples using this method:

SystemConfigurationMBS.ConsoleUserGID as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the group ID of the currently logged-in user.

The group ID of the current console user.

Some examples using this method:

SystemConfigurationMBS.ConsoleUserUID as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the user ID of the currently logged-in user.

The user ID of the current console user.

Some examples using this method:

SystemConfigurationMBS.LocalHostName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the current local host name.
Example
dim s as new SystemConfigurationMBS
msgbox s.LocalHostName

Returns the current local host name; "" if the name has not been set or if an error was encountered.

Some examples using this method:

SystemConfigurationMBS.Location as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
Gets the current location identifier.
Example
dim s as new SystemConfigurationMBS
msgbox s.Location

Returns a string representing the current location identifier; "" if no location identifier has been defined or if an error was encountered.

SystemConfigurationMBS.MachineName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
The local machine name.

SystemConfigurationMBS.NetworkCheckReachabilityByAddress(ip as string, byref flags as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 4.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Determines if the given network address is reachable using the current network configuration.

address: The network address of the desired host.
flags: An integer that will be filled with a set of SCNetworkConnectionFlags detailing the reachability of the specified address.
Returns true if the network connection flags are valid; false if the status could not be determined.
(see the SCNetworkReachabilityMBS class for more details)

Some examples using this method:

SystemConfigurationMBS.NetworkCheckReachabilityByName(nodename as string, byref flags as Integer) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 4.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Determines if the given network host/node name is reachable using the current network configuration.

nodename: The node name of the desired host.
flags: An integer that will be filled with a set of SCNetworkConnectionFlags detailing the reachability of the specified node name.
Returns true if the network connection flags are valid; false if the status could not be determined.
(see the SCNetworkReachabilityMBS class for more details)

Some examples using this method:

SystemConfigurationMBS.NetworkInterfaceRefreshConfiguration(ifname as CFStringMBS) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 4.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Sends a notification to interested configuration agents to have them immediately retry their configuration over a particular network interface.

This API must be invoked by root (uid == 0).
ifName: The BSD name of the network interface e.g. NewCFStringMBS("en0").
Returns true if the notification was sent; false otherwise.

SystemConfigurationMBS.ShortUserName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
The short user name.

SystemConfigurationMBS.UserName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method SystemConfiguration MBS MacCF Plugin 7.8 ✅ Yes ❌ No ❌ No ✅ Yes All
The user name.

The function UserName returns a string based on the read UID (RUID, as returned by getuid) of the calling process. This can result in unexpected behavior (that is, Name returning different results than ConsoleUser) for processes that manipulate their UID.

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


The biggest plugin in space...