GetMajorVersion
PowerScript function
Description
Returns the major version for the current PowerBuilder execution
context. For example, at maintenance level 11.5.1 the major version is
11.
Applies to
ContextInformation objects
Syntax
1 |
servicereference.GetMajorVersion ( majorversion ) |
Argument |
Description |
---|---|
servicereference |
Reference to the ContextInformation service |
majorversion |
Integer into which the function places the major |
Return value
Integer.
Returns 1 if the function succeeds and -1 if an error occurs.
Usage
Call this function to determine the current major version.
Examples
This example calls the GetMajorVersion function:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
String ls_name Constant String ls_currver = "8.0.3" Integer li_majver, li_minver, li_fixver ContextInformation ci this.GetContextService ("ContextInformation", ci) GetMajorVersion(li_majver) ci.GetMinorVersion(li_minver) ci.GetFixesVersion(li_fixver) IF li_majver <> 8 THEN MessageBox("Error", & "Must be at Version " + ls_currver) ELSEIF li_minver <> 0 THEN MessageBox("Error", & "Must be at Version " + ls_currver) ELSEIF li_fixver <> 3 THEN MessageBox("Error", & "Must be at Version " + ls_currver) END IF |
See also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest