Platforms to show: All Mac Windows Linux Cross-Platform

ArrayIsAMBS(v as Variant, ClassName as string) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
global method XojoRuntime MBS Util Plugin 12.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Checks if variant contains an array of the given class type.
Example
dim w() as MouseCursor
w.Append System.Cursors.ArrowEastWest
w.Append System.Cursors.ArrowNorthSouth

dim v as Variant = w

if ArrayIsAMBS(w, "MouseCursor") then
MsgBox "OK"
end if

If the variant contains an array of some class, variant or object and has at least one value, the plugin checks this first value for being of type of the same class. Like an ISA check.
This helps to solve feedback case 12213.
Returns false if variant has no array, if variant is nil, if array is not an array of objects or if first object is nil.

Blog Entries

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


The biggest plugin in space...