Does anyone know where I can find some examples for retrieving monikers (using aaApi_GetProjectMonikers and aaApi_MonikersToStrings) in PW SDK. I'm looking at trying to retrieve a full document/folder path from a document or from the address bar, but having some issues getting it to work.
Give this a try - assumes you have the project and document Id's (LONG lProjectId and LONG lDocumentId)
hMoniker = NULL;
aaItem.lProjectId = lProjectId;
aaItem.lDocumentId = lDocumentId;
BOOL bPassed = aaApi_GetDocumentMonikers(1L,&aaItem,hMoniker);
aaApi_MonikersToStrings(1L,hMoniker,&ppMonikerStr,AAMONIKERF_RESOURCE_LOCATION | AAMONIKERF_VISUAL);
//Get the string from *ppMonikerStr, do what you need
ppMonikerStr = NULL;
Please note that I post here on a voluntary basis and am not a Bentley employee.
Answer Verified By: Mark Shamoun
Thanks Jeff, that was exactly what i needed!
OpenRoads Designer 2022 R1 (10.11) | Microstation CE Update 17.2 | ProjectWise CE 3.4