Returns the comments attached to the given Mark-Up entry.
GSErrCode ACAPI_MarkUp_GetComments ( const API_Guid& markUpGuid, GS::Array<API_MarkUpCommentType>* commentList );
Parameters
- markUpGuid
- [in] GUID of the existing Mark-Up.
- commentList
- [out] The list of the comments.
Return Values
NoError
- The function has completed with success.
APIERR_BADPARS
- The passed
markUpGuid
parameter was incorrect or the passedcommentList
is nullptr.
For other common API errors see the API Errors document.
Remarks
Using this function the comments attached to an existing Mark-Up entry can be listed.
Use ACAPI_MarkUp_GetList function to return the list of all Mark-Up entries and ACAPI_MarkUp_AddComment function to add new comment to the Mark-Up.
Example
Mark-Up related code samples can be found in the MarkUp_Manager example add-on.
GS::Array<API_MarkUpCommentType> comments; ACAPI_MarkUp_GetComments (markUp.guid, &comments); WriteReport ("Comments:"); comments.Enumerate ([] (const API_MarkUpCommentType& comment) { WriteReport ("--------"); WriteReport ("\tAuthor: %s", comment.author.ToCStr ().Get ()); WriteReport ("\tCreation Time: %s", GSTimeToUniString (comment.creaTime).ToCStr ().Get ()); auto GetCommentStatusStr = [] (API_MarkUpCommentStatusID commentStatusID) -> const char* { switch (commentStatusID) { case APIComment_Error: return "Error"; case APIComment_Warning: return "Warning"; case APIComment_Info: return "Info"; case APIComment_Unknown: default: return "Unknown"; } }; WriteReport ("\tStatus: %s", GetCommentStatusStr (comment.status)); WriteReport ("\tText: %s", comment.text.ToCStr ().Get ()); WriteReport ("--------"); }); GS::Array<API_MarkUpType> markUpList; GSErrCode err = ACAPI_MarkUp_GetList (APINULLGuid, &markUpList);
Requirements
- Version: API 21 or later
- Header: ACAPinc.h
See Also
API_MarkUpCommentType, API_MarkUpType
ACAPI_MarkUp_AddComment, ACAPI_MarkUp_GetList
API Functions