How to get the Folders in my PDM tree

All topics about specific development with COM interface, LIP language, API in VB, ...

Moderators: remi77, jacs, Daniel

Post Reply
cam
Master Corporal
Master Corporal
Posts: 36
Joined: Fri Oct 02, 2009 9:46 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 7.8
Location: Germany

How to get the Folders in my PDM tree

Post by cam » Thu Oct 06, 2016 9:48 am

Hi there,

how can I get the folderstructure of my PDM ?
I try to write a little C# program that creates automaticly a project with a template in a specific folder in my PDM struture.
At the moment, the program creates the project direct under the root folder. I think the problem is that I don't know the root folder ID

void GetProjectFolderConstituents(
PdmProjectFolderId inProjectFolderdId,
out List<PdmProjectFolderId> outFolderIds,
out List<PdmObjectId> outProjectIds
)

Is this the methode to get the struture ?
How can I get the PdmProjectFolderId of the root folder ?
Last edited by cam on Tue Oct 25, 2016 2:32 pm, edited 1 time in total.
Greetings
Chris

AndiKS
Corporal
Corporal
Posts: 21
Joined: Fri Jul 31, 2009 10:43 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 7.8

Re: How to get the Folders in my PDM tree

Post by AndiKS » Thu Oct 06, 2016 6:44 pm

Hello,

There is a Constant for the Rootfolder:
TopSolidHost.Pdm.WorkingProjectsRootFolder

cu
Andi

Mark Oostveen
Chief
Chief
Posts: 107
Joined: Mon Mar 26, 2007 9:40 am
TopSolid Module: TopSolid'Cam
TopSolid Version: 7.8
Location: The netherlands
Contact:

Re: How to get the Folders in my PDM tree

Post by Mark Oostveen » Thu Aug 24, 2017 10:18 am

Hi,

I have a similar question. I want to "browse" through the "User Template projects" and "Compagny Template project" folders and list all available template projects.

I tried of two options.

1) Use the above WorkingProjectRootFolder constant and start from there. The "Template Project" folders however are not a part of the folderset in this root folder. So no luck

2) Use the GetTemplates option. This one returns the User- and CompagnyProjectTemplateFolder as PdmObjectID. Well great :) However If i want to use the GetProjectFolderConstituents I need a PdmProjectFolderId and not the given PdmObjectID. Casting does not seem to work. And I can't find a way to get from the one type to the oher.

Who can give me a hint?

Thanks

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest