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

Environment Variables in config.pro?

akelly
11-Garnet

Environment Variables in config.pro?

We have a couple of different ways that workstations are configured. Because some of the file paths are different, we need multiple config.pro files. It's kind of a pain to have multiple config.pro files and manage which ones are used on which workstation. We have automated scripts that "choose" the right config.pro, but we'd like to be able to reduce this down to a single config.pro that we can use that is independent of workstation configuration.

Is there a way that we can have the config.pro use Windows environment variables?

Andrew Kelly, P.E. | Senior Engineer | Crane Aerospace & Electronics | +1 440 326 5555 | F: +1 440 284 1090


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.
1 REPLY 1

Yes, if the environment variables are already set on the workstation,
you can simply use $"variable name" for the file path. Alternatively
you can edit the proe1.bat (calls proe.psf or proe.exe) and add lines
that set variables for that particular session or program.



For example you normally would see the line below detailing the full
path of the dtl file

drawing_setup_file
c:\stools\configuration\projects\wf3\config\english.dtl



This is further simplified by setting the environment variable SUTDATA
to c:\stools\configuration\projects\wf3, so we only need the following
in the config file.

drawing_setup_file $SUTDATA\config\english.dtl



If the SUTDATA location is different on another machine or user based,
we just control that environment variable and the config file will
remain the same.



Thanks,

Allen Caldwell



Allen Caldwell | PDC Manager | Project Engineer

P: 952-435-5533 x114 | F: 952-435-2440

EAC Product Development Solutions |


Top Tags