page_get_info_var_value

 

Description

Get the value of a variable in a Page's Info section

Syntax

bool page_get_info_var_value( Page & pg, LPCSTR lpcszVarName, string & strVal, LPCSTR lpcszStorageSection = NULL )

bool page_get_info_var_value( Page & pg, LPCSTR lpcszVarName, double & dVal, LPCSTR lpcszStorageSection = NULL )

Parameters

pg
[input] the page to get the value from
lpcszVarName
[input] pointer to the name of the variable
strVal
[output] the string to receive the value
lpcszStorageSection
[input] pointer to the name of the section. If NULL then the Variables section is used.

pg
[input] the page to get the value from
lpcszVarName
[input] pointer to the name of the variable
dVal
[output] the double to receive the value
lpcszStorageSection
[input] pointer to the name of the section. If NULL then the Variables section is used.

Return

If success then true else false


If success then true else false

Examples

EX1

void Run_page_get_info_var_value_Ex1()
{
    string     strVal;    
    Page pg("Book1");
    bool bRet = page_get_info_var_value(pg,"var",strVal,"user.var");        
}


EX2

void Run_page_get_info_var_value_Ex2()
{
    double     dVal;    
    Page pg("Book1");
    bool bRet = page_get_info_var_value(pg,"var",dVal,"user.var");        
}

Remark

See Also

page_set_info_var_value

header to Include

origin.h

Reference