Default constructor for a PageBase object.
Construct a PageBase object using the name of an existing page.
Construct a PageBase object using another PageBase object.
PageBase( )
PageBase( LPCSTR lpcszName )
PageBase( PageBase & page )
EX1
// Defualt construction void PageBase_PageBase_ex1() { PageBase pbTemp; // Defualt construction, object is not valid at this point pbTemp = Project.Pages(); // Get the project's active page if( pbTemp.IsValid() ) printf("Active page is of type %d\n", pbTemp.GetType()); else printf("Active page is invalid\n"); }
EX2
//Construct by name void PageBase_PageBase_ex2() { string strName = "ABC"; PageBase pb(strName); // Construct by name if( pb.IsValid() ) printf("Page %s is of type %d\n", strName, pb.GetType()); else printf("Page %s is invalid\n", strName); }
EX3
//Construct by other PageBase object void PageBase_PageBase_ex3() { string strName = "ABC"; PageBase pb1(strName); // Construct by name PageBase pb2(pb1); // Construct by other PageBase object if( pb2.IsValid() ) printf("Page %s is of type %d\n", strName, pb2.GetType()); else printf("Page %s is invalid\n", strName); }
origin.h