Returns information on the current project file.
GSErrCode ACAPI_Environment ( APIEnv_ProjectID, API_ProjectInfo* projectInfo );
Parameters
- projectInfo
- [out] Project file and teamwork project specific data.
Return Values
NoError
- No error occurred.
APIERR_BADPARS
projectInfo
isnullptr
.APIERR_NOPLAN
- No open project.
APIERR_MEMFULL
- Low memory condition.
For other common API errors see the API Errors document.
Remarks
This function is used to get information on the project file. In teamwork mode, the teamwork related data are also available. See the definitions of the returned parameters at API_ProjectInfo.
The file specification is available only if the project file has been saved before. For ‘untitled’ project no data is returned.
The dynamic memory allocated by this function will be deleted in the destructor of the API_ProjectInfo structure.
Example
API_ProjectInfo projectInfo = {}; ACAPI_Environment (APIEnv_ProjectID, &projectInfo);
Requirements
- Version: API 2.1 or later
- Header: APIdefs_Environment.h