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 an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Preventing two sessions of Pro/E

STEVEG
21-Topaz I

Preventing two sessions of Pro/E

I have our Pro/E startup batch files checking if a session of Pro/E is already running. If so then it will notify the user and it will not start a second one. This has worked great.I modifed the batch file in the bin directory. However, I just ran into a case where a user double-clicked a model in an Explorer window and it started up a second session.

Since I can't change the proe.exe file in the bin directory do you know how I could prevent this from happening, aside from going to every computer and edit the file association? Or is there a way to change that association in our startup batch file?

Steve G
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.
4 REPLIES 4
JohnGetty
12-Amethyst
(To:STEVEG)

You can set that from your startup batch file if everyone is running the
same batch file. Look in the registry under
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Extensions
to change it globally or
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Extensions
for a per user change. If the batch file exists on each local machine,
you would have to get a list of the machines on your network and push
the change remotely.



John


egifford
12-Amethyst
(To:STEVEG)

Steve,

You can prevent users from running more than one session of Pro/E through the license service as well. Set up an options file for the FlexNetlicenseservice for yourPTC software and edit the license file to point to the options file. In the options fileyou can utilize the MAX option to specify a maximum of one concurrent license of Pro/E for each user. The upside of this is you get tight central control and can allow certain users multiple licenses while limiting most users to one license. The downside is, at least this is what I found, you have to have a "MAX" line in the option file for each user name. The options file does permit creating groups of users to allow easier application of controls, but using MAX and groups together sets that whole group of users collectively to a limit of 1 license - not what you want (at least that's what I reacall from several years ago - if anyone found differently please correct me because that would change things). If you have a small to mediumnumber of users it's easy to manage this way, but if you have hundreds of users, frequent contract workers or a user list constantly in a state of flux, this approach can get too complicated to realistically manage.

Erik

STEVEG
21-Topaz I
(To:STEVEG)

There were some very helpful suggestion but the one I have decided to use was from David Graham. However, I have not tried it yet.

Thank you very much David.

you can remove the association in your batch file.

The command to do this is assoc. So, to remove all associations you would want to run
assoc .prt=
assoc.asm=
assoc .drw=
assoc.frm=

The syntax above will remove the association.

To see the current association:
assoc .prt

To restore the association:
assoc .prt=prtFile

Steve G
STEVEG
21-Topaz I
(To:STEVEG)

I just wanted to show what I ended up doing with this.

The command <u>assoc .prt=</u> was not the only command I needed. I also needed <u>assoc .1=</u>

If you look at the File Types tab from the Folder Options in an explorer window there are also associations for 1 - 250 to use Pro/E to open. And since Pro/E increments their CAD files with integers, I had to remove those association in addition to .prt, .asm, and .drw.

Ina text file pro_file_assoc.txt I added one integer digit extensionper line. I.e.:

.1

.2

etc up to .40 along with .prt, .asm, and .drw.

This text file is on the network.

In our startup script Ifirstadded code torecordeach usersfile association to a text file.That is just incase a particular computer had a different program associated to one or more of the file extensions:

if not exist %PRO_LOG%\%username%_%computername%_file_assoc.txt (
for /F "skip=1" %%a in (%PRO_NCONFIG%\pro_file_assoc.txt) do (
assoc %%a >> %PRO_LOG%\%username%_%computername%_file_assoc.txt)
)

Then I added the line to remove the association:

for /F "skip=1" %%a in (%PRO_NCONFIG%\pro_file_assoc.txt) do (assoc %%a=)

I can always add more extension digits later to the text file if I need to.

Steve G

Announcements
NEW Creo+ Topics: PTC Control Center and Creo+ Portal


Top Tags