AxisObject::SetTypeFormatEtc

Description

to set the type of tick label

Syntax

int SetTypeFormatEtc( int nType, LPCSTR lpcsz, int nFormat = -1 )

Parameters

nType
[input]Axis label type, enum as OULABELTYPE
lpcsz
[input]Text string for specific types :
For OULABEL_TEXT, OULABEL_DATASET, OULABEL_CATEGORICAL, it means dataset name
For OULABEL_STROBJ, it means tick-indexed string.
For other types, it should be NULL.
nFormat
[input]Display format for OULABEL_NUMERIC, OULABEL_TIME, OULABEL_DATE, OULABEL_MONTH, OULABEL_DAYOFWEEK, OULABEL_COLUMN

Return

Return 0 if no error, otherwise error code enumeration as AXISLABELACCESSERROR

Examples

//Set the tick label with tick-indexed string:"tick1 tick2 tick3".
void AxisObject_SetTypeFormatEtc_Ex1()
{
        GraphLayer gl = Project.ActiveLayer();    
 
    AxisObject aoXLabel = gl.XAxis.AxisObjects(AXISOBJPOS_LABEL_FIRST);
    
    int    nType =9;
    string str ="tick1 tick2 tick3";
    aoXLabel.SetTypeFormatEtc(nType, str);
        
}

Remark

See Also

GetTypeFormatEtc

header to Included

origin.h