cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X

Using Search Paths in Assembly Folder

AdmirPlecic
1-Visitor

Using Search Paths in Assembly Folder

I'm having trouble managing components that are used in multiple different assemblies. For example, I have a "Bearing Housing" component that is used in two main assemblies: "Large Housing" and "Small Housing". The way i do things currently, I have to have Bearing Housing.prt file saved in both assembly folders.

Is there a way to use shortcuts or pointer files?

I would like to have one master Bearing_Housing.prt file and shortcuts / pointers to that file in Large Housing and Small Housing folders. I'm aware that i could just not have the Bearing_Housing.prt file in either of the two folders, but in that case i would have to retrieve the file afer i open the assembly, or have Bearing_Housing.prt in session before i open either of them. I don't want to have those limitations, if possible.

I'm using WF5 M040, and I don't have Windchill...


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
7 REPLIES 7

Search paths is what I was looking for...

However, I could still use some clarification; If i place a search path option in my config file I would have to have multiple config files. How do you manage those? How do you tell Pro-E which one to open?

I was thinking about placing a search path file in the same directory as the assembly file, and set options in the config file to look for search path file in the work directory. Only Issue with that is having to designate the work directory every time I want to open an assembly. Also, I would not be able to open more than one assembly at a time, since you can't have more than one work directory at the same time.

Does anyone have a solution for this issue?

Admir,

You actually have two options, based on two different config settings (you do not need multiple config files):

search_path

search_path_file

If you use search_path you can have more than one file designated in your config file. However, if you have more than a few files, the better option is to use the search_path_file option. With the latter option, you simply designate the full path and file name of a text file that has each desired path-file listed, one per line. Then, to add paths, you don't have to modify your config file; just modify the text file.

David

P.S. Rereading your second post, a couple more comments:

(1) You can have assemblies from different directories open at the same time, even though you can have only one Working Directory at a time, but I don't think that is relevant to your underlying question, and you can make a mess of things when you start saving things to the wrong directory.

(2) If you really want your Working Directory to be designated by the search_path option (not sure why you would want to do this), you can always create a temporary one-line config file in your Working Directory during a particular working session. (You can always load or create specialty config files in addition to the primary config files that are loaded automatically.)

Thanks for your reply David,

My main problem is that I want anybody to be able to open an assembly file (without having to mess around with config files), and have that file (or something tied / related to it) itself point to all the required folders. I thought about designating the working directory in the config file because the person opening the assembly would just have to set the proper working directory, which is not too hard. Also, I was unaware of temporary config files.

BTW, can i add search_path to assembly parameters? If i could somehow insert search_path and make it part of the assembly file, that would do it.

Admir,

I'm a little puzzled by your questions, but maybe I can make things clearer. There is no way that I am aware of to have search_path information attached to a particular assembly file itself, I'm still not sure what you would gain by having the Working Directory specified as a search_path location. Search path settings are established in config files. What most folks would do is have every user's config file point to the same reference(s). In this case, I would have the top level config file in every users loadpoint text directory have a search_path_file line pointing to the same shared file. The file could have several locations listed for Hardware, Motors, Cylinders, General Sub-assemblies, etc.

I don't know what you mean by a search_path for assembly parameters. What is it you are trying to accomplish?

David

Here is my issue:

We keep component files in folder tree based on customer primarily. So, for customer A, there will be a main folder. In that folder there will be a few folders for programs B, C, D. Each one of those folders will have sub folders for Product A, B, C etc. I want to be able to share components between these products.

These components will not only be washers and bolts, nuts but actual parts that I don't want pulled into other customer's assemblies accidentally.

So, since I don't know how search paths function, I thought that naming (in options) work directory as a location for search path file, I could manipulate where Pro_E looks for components just by changing the work directory. When I set directory A as my work directory, there will be a search path file in work directory A that will point to all the file locations for that customer.

When I say "search path for assembly parameters" I mean a search path that is part of that assembly file. That way anyone who opens that assembly file also gets the search_path option with it, and all the parts are loaded without him/her having to have the search_path in their config file.

On the other hand, maybe I'm just looking at this completely wrong... Is it possible to set-up a search path so all the sub-folders are searched without actually naming them all? That way you can point it to the network drive with all the part files and it does the rest, even if somenone adds a folder somewhere deep inside the tree months later.

Admir,

Thanks, I now understand your problem more clearly.

You can do something like what you have in mind in a slightly different way than you imagined. It will take a little--not much--work to set up. Rather than creating "parameters" attached to an individual Assembly, you can create a one-line config file in each Working Directory. If you use similar naming conventions, say including a sub-directory for each customer or project called "Common Parts", this will be even easier, because you can Copy, Paste, and slightly edit the one-line config file in all your critical directories. Then when you set one of these Working Directories, you simply load the config file from that directory. The best way to do that is to create a mapkey that will automate the process, requiring just one pick of the file name from the Working Directory list. Your users would then just hit one key and pick the "local" config file every time they set a Working Directory. If you want to try this approach, I can give you a little more detail.

What you do not want to do is what you suggested at the end of your last post, because retrieval time would suddenly become ridiculous as the system searched all directories. That's the whole point of search-path options: to expand beyond the Working Directory only as far as necessary.

David

Announcements
NEW Creo+ Topics: Real-time Collaboration


Top Tags