Platforms to show: All Mac Windows Linux Cross-Platform

GetVariantTypeMBS(va as variant) as Integer
Type Topic Plugin Version macOS Windows Linux iOS Targets
global method XojoRuntime MBS Util Plugin 20.5 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Function: Queries variant type.
Dim i As Int32 = 5
Dim u As UInt32 = 5
Dim vi As Variant = i
Dim vu As Variant = u
Dim ti As Integer = vi.Type // 2
Dim tu As Integer = vu.Type // 2
Dim mi As Integer = GetVariantTypeMBS(vi) // 2
Dim mu As Integer = GetVariantTypeMBS(vu) // 102

Break // check in debugger
Same as variant.type or VarType() function, but returns 102 for UInt32 and 103 for UInt64.
This way plugin functions internally can distinguish between variants with unsigned vs. signed data types.

Some FAQ entries about this method:

Blog Entries

Xojo Developer Magazine

Feedback, Comments & Corrections

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

The biggest plugin in space...

MBS Xojo PDF Plugins

Start Chat