GETN_CHECK

 

Name

GETN_CHECK

Declaration

#define GETN_CHECK(_NODE_NAME, _NODE_LABEL, _DEFAULT_VAL)  _tmpSubNode = _tmpNode.AddNumericNode((int)_DEFAULT_VAL, #_NODE_NAME, TRGP_CHECK);TREE_ADD_LABEL(_NODE_LABEL);

Remark

This macro creates a checkbox control in the GetN_Box dialog box.

Parameters

_NODE_NAME
[input] the name of the new node to be added to GetN_Box tree
_NODE_LABEL
[input] the string value to show the checkbox control in the dialogbox.
_DEFAULT_VAL
[input] integer contents as the default value to show in the combo box
>0 The checkbox is checked as default.
<=0 The checkbox is unchecked as default.

Return

Examples

EX1

#include <GetNbox.h>

void GETN_PASSWORD_ex1()
{
    GETN_BOX( treeTest )
    GETN_BEGIN_BRANCH(trBranch, " ") GETN_OPTION_BRANCH(GETNBRANCH_OPEN)
    GETN_MULTI_COLS_BRANCH(2, DYNA_MULTI_COLS_COMAPCT) 
                GETN_PASSWORD(Key, "PassWord", " ")
                GETN_PAD(dummy)
                GETN_CHECK(View, "View", 0) 
                GETN_STR(Info, "", "") GETN_INFO
        GETN_END_BRANCH(trBranch)
    
    if( GetNBox( treeTest, _pw_event_func_ex, "Title PassWord", "Input PassWord") )
    {
        out_tree( treeTest );
    }
}

static int _pw_event_func_ex(TreeNode& tr, int nRow, int nEvent, DWORD& dwEnables, LPCSTR lpcszNodeName, WndContainer& getNContainer, string& strAux, string& strErrMsg)
{   
    if(1 == tr.trBranch.View.nVal)
        tr.trBranch.Info.strVal = tr.trBranch.Key.strVal;
    else
        tr.trBranch.Info.strVal = "";
    
    return 0;
}

See Also

GETN_CHECKBOX_BRANCH

header to Include

GetNbox.h

Reference