Hi,
To access the format tree of axis you want, you can get the format tree and output this format tree after setting in GUI. In your issue, you can done in the Axis dialog using the Custom Tick Labels tab, and then run the following code.
void accessSpecialLabel()
{
GraphLayer gl = Project.ActiveLayer();
if(!gl)
return;
Axis aX = gl.XAxis;
if(!aX)
return;
Tree trFormat;
// need to change the Special setting to get the corresponding tree node
trFormat = aX.GetFormat(FPB_ALL, FOB_ALL, TRUE, TRUE); // get the tree format of X axis
out_tree(trFormat); // output tree format, then can see the tree node you want
// set the tree node value you want
trFormat.Root.Labels.BottomLabels.Custom.Special.Type.nVal = 3; // set to Manual
trFormat.Root.Labels.BottomLabels.Custom.Special.Label.nVal = 0; // set label to 0, no decimal place
trFormat.Root.Labels.BottomLabels.Custom.Special.Value.dVal = 0.0; // value point to set
int nErr = aX.UpdateThemeIDs(trFormat.Root);
if(0!=nErr)
out_str("Error");
aX.ApplyFormat(trFormat, true, true, true); // apply format to X axis
}
This page has provided some examples about how to access graph format with theme tree and they may be helpful.
Penn