APIDo_​NewProjectID

Opens a new plan.

    GSErrCode ACAPI_Automate (
        APIDo_NewProjectID,
        API_NewProjectPars*     newProjectPars
    );

 

Parameters

newProjectPars
[in] Parameters for opening a new project.

 

Return Values

NoError
The function has completed with success.
APIERR_BADPARS
newplanPars is nullptr
APIERR_REFUSEDCMD
the function is called from notification level

For other common API errors see the API Errors document.

 

Remarks

This function is used to perform a New or a New and reset command in the server application.

It cannot be called from notification level; the command is refused if other addons are running. Calling this function may notify other addons on the event. The caller addon does not get any notification. See the Notification Manager for further details.

This function performs complete operations, so it cannot be called neither during undoable operations nor during non-undoable commands. See more details on this topic at Command Overview.

 

Example


API_NewProjectPars  newPlanPars;

BNZeroMemory (&newPlanPars, sizeof (API_NewProjectPars));
newPlanPars.newAndReset = true;

ACAPI_Automate (APIDo_NewProjectID, &newPlanPars, nullptr);

 

Requirements

Version: API 2.1 or later
Header: APIdefs_Automate.h

 

See Also

API_NewProjectPars,
ACAPI_Automate, API Functions