WorksheetPage::WorksheetPage

Description

Construct a WorksheetPage object using the name of an existing Origin worksheet page.


Construct a WorksheetPage object using an existing WorksheetPage object.

Syntax

WorksheetPage( LPCTSTR lpcszName )

WorksheetPage( PageBase & page )

Parameters

lpcszName
[input]The name of an existing Origin worksheet page.

page
[input]A reference to an existing WorksheetPage object.

Return

Examples

EX1

//Construct a WorksheetPage object using the name of an existing Origin worksheet page
int WorksheetPage_WorksheetPage_ex1()
{
    WorksheetPage wp;
    wp.Create("Origin");
    if( wp.IsValid() )
    {
        WorksheetPage wp2(wp.GetName());
        if( wp2.IsValid() )
            printf("wp and wp2 are both attached to '%s'\n", wp2.GetName());
    }
    return 0;
}


EX2

//Construct a WorksheetPage object using an existing WorksheetPage object
int WorksheetPage_WorksheetPage_ex2()
{
    WorksheetPage wp;
    wp.Create("Origin");
    if( wp.IsValid() )
    {
        WorksheetPage wp2(wp);
        if( wp2.IsValid() )
            printf("wp and wp2 are both attached to '%s'\n", wp2.GetName());
    }
    return 0;
}

Remark

Construct a WorksheetPage object using an existing WorksheetPage object.

See Also

Page::Create

header to Include

origin.h