Ext.SetCompatibilityVersion()

Controls how Variants interact with dates.

Function Signature

 bool Ext.SetCompatibilityVersion( majorVersion [, minorVersion] )

Parameters

Parameter Type Description

majorVersion

int

This is the major version number for the version of SBM with which you want the script to be compatible.

CAUTION:
Do not use a version number containing a period as an argument (for example, 11.4)). SBM ModScript interprets a single argument as a major version number with a default minor version of 0, throwing away the period and everything after it.

minorVersion

int

Optional; 0 by default. This is the minor version number for the version of SBM with which you want your script to be compatible.

Return

Type Description

bool

Returns true.

Technical Details

SBM ModScript version: 11.3.

Notes

The SBM ModScript default compatibility version is 11.3. Scripts converted from SBM AppScript using the conversion utility will invoke ConvertedFromAppScript(), which will set the compatibility value to 0.0 (which is the default for SBM AppScript). The script may proceed to invoke Ext.SetCompatibilityVersion() to change the value again.

The compatibility version controls how Variant interacts with dates:

Tip: The preferred option for interacting with dates is with either the TimeT or TimeMillis classes.

Related Topics

Extension Functions

Ext.GetCompatibilityVersion()

SBM AppScript Conversion Functions