Get<type>GlobalVar

PowerBuilder Native Interface

IPB_Session interface:

Get<type>GlobalVar method

Description

A set of methods that gets the value of a global variable of a specific datatype.

Syntax

GetArrayGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetBlobGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetBoolGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetByteGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetCharGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetDateGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetDateTimeGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetDecGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetDoubleGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetIntGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetLongGlobalVar( pbfieldID fid, pbboolean& isNull ) 
GetLongLongGlobalVar( pbfieldID fid, pbboolean& isNull ) 
GetObjectGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetRealGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetStringGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetTimeGlobalVar ( pbfieldID fid, pbint value ) 
GetUintGlobalVar ( pbfieldID fid, pbboolean& isNull ) 
GetUlongGlobalVar ( pbfieldID fid, pbboolean& isNull ) 

Argument

Description

fid

The field ID of the global variable

isNull

Indicates whether the variable is null

Return Values

A predefined PBNI datatype that corresponds to the PowerBuilder datatype in the method name.

Examples

This code gets the value of a global variable of datatype long using its field ID:

fid = session -> GetGlobalVarID("l_gvar");
l_val = session -> GetLongGlobalVar(fid, isNull);
session -> SetLongGlobalVar(fid, l_val + 1);

See Also