Platforms to show: All Mac Windows Linux Cross-Platform

Back to SystemInformationMBS module.

SystemInformationMBS.MACAddress as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ✅ Yes ✅ Yes ❌ No Desktop, Console & Web
Returns the hardware ethernet address of the first ethernet card.
Example
msgBox SystemInformationMBS.MACAddress

It returns a string with 6 bytes.
Works now with MBS Plugin 2.6 for Mac OS Classic, Carbon inside Classic and Mac OS X, but may not work for a Classic application running on Mac OS X. And may fail on some machines if no OpenTransport is running.

On Windows and Mac OS X you can have multiple ethernet cards and you should use a command line tool with the shell class to find what you need.

For example on Windows:

ipconfig /all

or on Mac OS X:

ifconfig -a

You can replace this function with usage of the NetworkInterface class in newer RB versions.

Added Linux support in version 16.4.

SystemInformationMBS.MACAddressString as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ✅ Yes ✅ Yes ❌ No Desktop, Console & Web
Returns the hardware ethernet address of the first ethernet card.
Example
msgBox SystemInformationMBS.MACAddressString

Same as MACAddress, but with different format of output.

You can replace this function with usage of the NetworkInterface class in newer RB versions.

The plugin asks on Mac OS X the IOKit framework for the primary ethernet interface. We are not sure what Apple really defines for being the primary one, so let's test it:

  • Ethernet on and Airport off -> Ethernet MAC Address
  • Ethernet off and Airport on -> Ethernet MAC Address

Added Linux support in version 16.4.

Some examples using this method:

SystemInformationMBS.MacBoardID as string   Deprecated

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 19.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
This item is deprecated and should no longer be used.
Queries board-id for Mac.
Example
MsgBox SystemInformationMBS.MacBoardID

e.g. "Mac-1234567890123456"

SystemInformationMBS.MacBugFixVersion as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 10.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The BugFix part of the Mac OS version number.
Example
MsgBox str(SystemInformationMBS.MacBugFixVersion)

The bug fix system version number; in 10.4.17 this would be the decimal value 17.

Intel apps running in Rosetta on Apple M1 will report 10.16 instead of 11.x.

Some examples using this method:

SystemInformationMBS.MacHasHardwareAcceleratedCoreImage as boolean   Deprecated

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
This item is deprecated and should no longer be used.
Queries whether hardware acceleration is used for CoreImage.
Example
if SystemInformationMBS.MacHasHardwareAcceleratedCoreImage then
msgbox "CoreImage should be very fast."
else
msgbox "CoreImage may be slow."
end if

Queries OpenGL whether programmable fragments are supported.

SystemInformationMBS.MachineID(flags as Integer = 15) as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 10.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Returns a Machine ID for the current computer.
Example
// this is how we build it.
Var t as string = "MachineID"+SystemInformationMBS.HardDiscSerial+SystemInformationMBS.MacSerialNumber+SystemInformationMBS.MacModel+SystemInformationMBS.CPUBrandString

// you could extend it with SystemInformationMBS.WinProductKey

Var m as string = MD5StringMBS(t)

MsgBox "Machine ID: "+SystemInformationMBS.MachineID+EndOfLine+"My Machine ID: "+m

Returns a 32 byte long hex string with a Machine ID.
Example value: "EE537483656B25996B51B7F4C99F9083".

This ID is based on the results of the MacSerialNumber, MacModel, CPUBrandString and HardDiscSerial functions. If all 4 functions have no value, the result is always "A2254DEF74A74608D76D1BA49BD2E82A". Also the result could change in future if we fix a bug in one of the functions so that the result values differ.

It is not based on the MACAddressString function as your MAC Address can change when switching between wired and wireless networks. Also we do not check the PhysicalRAM as RAM is a typical thing which changes over time.

You can store this value in some prerences/license file and later compare it agains the current value to see if the machine may have changed. In that case ask user to revalidate license, for example by asking for the serial number.

It can happen that 2 PCs have the same MachineID, typical two virtual machines. So this ID is not unique. But it is very likely that two different computers produce different MachineIDs.

Added flags parameter in 14.1:
flagHardDiscSerial1Use hard disk serial.
flagMacSerialNumber2Use Mac Serial number (on Mac)
flagMacModel4Use Mac Model (on Mac)
flagCPUBrandString8Use CPU Brand String.
flagWinProductKey16Use Product Key (on Windows only)

The Machine ID may be different if one of the components returns a different result. Result may be different in whether app runs as admin or not on Windows.

In Windows 8.1 it looks like WindowsWMIMBS.InitSecurity(false) must be called at app.open time as Xojo will do some things in background when opening first window which block our queries.

SystemInformationMBS.MacMajorVersion as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 10.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The major Mac OS version number.
Example
// show major version number
MsgBox str(SystemInformationMBS.MacMajorVersion)

// and show all three version numbers together:
MsgBox str(SystemInformationMBS.MacMajorVersion)+"."+str(SystemInformationMBS.MacMinorVersion)+"."+str(SystemInformationMBS.MacBugFixVersion)

The major system version number; in 10.4.17 this would be the decimal value 10.

On macOS Big Sur, this returns 11 in Apple Silicon application and 10 in Intel application.
On macOS Monterey this returns 12.
If your Intel application is build with older SDK (e.g. Xojo 2019), the result reported version will still be macOS 10.16.

Some examples using this method:

SystemInformationMBS.MacMinorVersion as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 10.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The minor Mac OS version number.
Example
MsgBox str(SystemInformationMBS.MacMinorVersion)

The minor system version number; in 10.4.17 this would be the decimal value 4.

Some examples using this method:

SystemInformationMBS.MacModel as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Returns the Mac model string.
Example
msgbox SystemInformationMBS.MacModel

for example "<powermac7,3>".

Some examples using this method:

SystemInformationMBS.MacProductName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 25.4 ✅ Yes ✅ Yes ✅ Yes ❌ No Desktop, Console & Web
Queries the product name of the Mac.
Example
MessageBox _
SystemInformationMBS.MacProductName + EndOfLine + _
SystemInformationMBS.MacProductSOCName + EndOfLine + _
SystemInformationMBS.MacModel + EndOfLine + _
SystemInformationMBS.ComputerName

Only for Apple Silicon Macs.

SystemInformationMBS.MacProductSOCName as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 25.4 ✅ Yes ✅ Yes ✅ Yes ❌ No Desktop, Console & Web
Queries the name of the system on chip in a Mac.
Example
MessageBox _
SystemInformationMBS.MacProductName + EndOfLine + _
SystemInformationMBS.MacProductSOCName + EndOfLine + _
SystemInformationMBS.MacModel + EndOfLine + _
SystemInformationMBS.ComputerName

Only for Apple Silicon Macs.

SystemInformationMBS.MacROMBootVersion as string   Deprecated

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 19.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
This item is deprecated and should no longer be used.
Returns boot ROM version string.
Example
MsgBox SystemInformationMBS.MacROMBootVersion

e.g. "220.270.99.0.0 (iBridge: 16.16.6571.0.0,0)"

SystemInformationMBS.MacSerialNumber as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Returns the serial number of your local Mac.
Example
msgbox SystemInformationMBS.MacSerialNumber

May return an empty string in case of an error.
(e.g. when being user on Windows or if the Mac does not know its serialnumber)

Some examples using this method:

SystemInformationMBS.MacUUID as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Returns the unique identifier for the given Mac.
Example
msgbox SystemInformationMBS.MacUUID

Returns "" on any error.

Some examples using this method:

SystemInformationMBS.MacVRAMSize as Int64   Deprecated

Type Topic Plugin Version macOS Windows Linux iOS Targets
method System MBS Util Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
This item is deprecated and should no longer be used.
Queries the size of the main video graphics memory size.
Example
msgbox format(SystemInformationMBS.MacVRAMSize,"0")+" Bytes VRAM."

Walks over the list of displays, asks on each display for its VRAM size and returns the first value found.

For some reason this seems not to return more than 256 MB of memory.

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


The biggest plugin in space...