Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
Hi all,
I am currently developing a C++ toolkit customization for Workgroup Manager and I am using the workspace viewer (wwgmtkWorkspaceViewer_ptr) function getWorkspaceObjectByEpmName() to search for a specific EPM Document by its filename. From my initial testing, it appears that the getWorkspaceObjectByEpmName() function searches the current local workspace as intended, but also the Windchill commonspace which is not desired. Can anyone confirm this functionality and educate me on how to prevent searching commonspace?
If searching the Windchill commonspace is by design and there is not a workaround, does anyone know how to determine if the returned workspace object (wwgmtkWorkspaceObject_ptr or wwgmtkEpmDocument_ptr) was located in the local workspace or commonspace?
I haven't been able to answer my original questions yet, but as a potential workaround, I am using the getWLDPath() function from the wwgmtkWorkspace_ptr object to determine the local folder location of the workspace. Next, I concatenate the folder location with the EPM document file name and check to see if the actual file exists in the workspace (i.e. "%USERPROFILE%\Documents\PTC Places\Workspace\ABC123.SLDDRW").
Worth to mention for wwgmtkWorkspace::getWLDPath():
Get path of Workspace Local Directory for the given application
|
appName can be NULL (at least in my tests with Windchill & WWGM 11.0 M030).
I struggled figuring out the authoring application name - trying some variants of AutoDesk Inventor.... 😬