Get the information tree of the DataRange.
void PrepareTree( TreeNode & tr )
//Get the information tree of the DataRange. void DataRangeEx_PrepareTree_Ex1() { //assume the active workbooka sheet and has least four columns before run this code. Worksheet wks = Project.ActiveLayer(); if ( !wks ) { printf("Can not find any active worksheet!"); return; } DataRange dr; dr.Create();//init the object dr.Add("X", wks, 0, 0, -1, 0); dr.Add("Y", wks, 0, 1, -1, 1); dr.Add("X", wks, 0, 2, -1, 2); dr.Add("Y", wks, 0, 3, -1, 3); Tree trData; dr.GetTree(trData); DataRangeEx drEx; drEx.Create(trData, true); Tree trPrepare; drEx.PrepareTree(trPrepare); return; }
origin.h