| 2.2.4.8.13 DataPlot::GetDescription
 DescriptionGet description string.
 SyntaxBOOL GetDescription( string & strValue, BOOL bGetRangeString = FALSE, DWORD dwCntrl = 0 ) Parameters strValue[output] the description string bGetRangeString[input] Z header name or range string, valid when from virtual matrix dwCntrl[input]when from virtual matrix(valid when bGetRangeString = TRUE):NTYPE_NAMED_RANGEelseGETLC_NO_ROWSGETLC_COL_SHORT_NAME
 ReturnTRUE if successful, otherwise FALSE
 ExamplesEX1
 void DataPlot_GetDescription_ex1()
{
    Worksheet wks;
    wks.Create("origin");
    Dataset ds1(wks,0);
    Dataset ds2(wks,1);
    ds1.Data(1,20,1);
    ds2.Normal(20);
    GraphPage gp;
    gp.Create("origin");
    GraphLayer gl(gp.GetName(), 0);
    gl.AddPlot(wks);
 
    if(gl)
    {
        DataPlot dp = gl.DataPlots(0); 
    
        string strDescription;
        dp.GetDescription(strDescription, FALSE, GETLC_NO_ROWS | GETLC_COL_SHORT_NAME);
 
        printf("GetDescription: %s\n", strDescription);
    }
}EX2
 //assume there is a plot from virtual matrix in the layer
void DataPlot_GetDescription_ex2()
{
    GraphLayer gl = Project.ActiveLayer();
    if(!gl) 
        return;
 
    DataPlot dp = gl.DataPlots(0); 
    
    string strDescription;
    dp.GetDescription(strDescription, FALSE);
    printf("GetDescription: %s\n", strDescription);
    
    dp.GetDescription(strDescription, TRUE);
    printf("GetDescription: %s\n", strDescription);
    
    dp.GetDescription(strDescription, TRUE, NTYPE_NAMED_RANGE);
    printf("GetDescription: %s\n", strDescription);
}RemarkSee AlsoHeader to Includedorigin.h
 |