Open
Open a new project, or append a project. Current project will be closed and replace with the new one if successful
BOOL Open( LPCSTR lpcszFilename = NULL, int nOptions = OPJ_OPEN_NORMAL )
TRUE for success, this method will check file existence before attempting to open, so will immediately return FALSE if file does not exist
EX1
// For this example to run, make sure that the variable strPathName inside // the function is initialized to the pathname of an existing project file. void Project_Open_Ex1() //Open a new project { string strPathName = "c:\\myproject.opj"; if (Project.Open(strPathName)) out_str("Project opening succeeded."); else out_str("Project opening failed!"); } void Project_Open_Ex2() //Append myproject.opj to the current project. Use current folder as root to append all contents. { string strPathName = "c:\\myproject.opj"; if (Project.Open(strPathName, OPJ_OPEN_APPEND)) out_str("Project appending succeeded."); else out_str("Project appending failed!"); } //OPJ_OPEN_APPEND_NEW_FOLDER void Project_Open_Ex3() //Append myproject.opj to the current project. Use OPJ filename to create a subfolder in current folder { string strPathName = "c:\\myproject.opj"; if (Project.Open(strPathName, OPJ_OPEN_APPEND_NEW_FOLDER)) out_str("Project appending succeeded."); else out_str("Project appending failed!"); }
Project::Save
origin.h