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

How to assign model name to default CSYS

MartinHanak
Emerald IV

How to assign model name to default CSYS

This discussion is my reaction to CSYS name should alway be the Part Name idea.

 

Attached CSYS_rename_CR3_prvek4.zip file contains following files:

 

How to install script:

  1. create C:\PTC directory
  2. save zip file into C:\PTC directory
  3. unzip zip file into C:\PTC directory to get structure show on picture
  4. open config.pro file and copy two lines into your config.pro

 

How to run script:

  1. launch Creo 3.0 (in my case it is M100, English version)
  2. open part
  3. run mapkey dd1
  4. open assembly
  5. run mapkey dd2

 

Notes:

  • .au3 ... source file
  • .exe ... compiled source file
  • if you unzip zip file into directory different from C:\PTC, then you have to modify path defined in config.pro
  • notes in source file are written in Czech language, I hope that translate.google.com transfers Czech texts into English properly

 

Good luck !

 

Martin Hanak


Martin Hanák
17 REPLIES 17

Re: How to assign model name to default CSYS

Hi Martin!,

Thank you for this tool with source code. This gives a whole new level to Creo Mapkeys combined with external application. And it's pretty clever how you did the renaming.

I didn't know, something like this is possible! I cannot say my thanks with words!

I wanted to ask, if you could share the $F2-mapkey you are using for this renaming method of CSYS. I have original scripts from IPM with $F2 for opening model tree, so the .exe files don't work for me.

Thanks again and I wish you the best!

Re: How to assign model name to default CSYS

Hi,

I don not understand well your last paragraph:

I wanted to ask, if you could share the $F2-mapkey you are using for this renaming method of CSYS. I have original scripts from IPM with $F2 for opening model tree, so the .exe files don't work for me.

My guess ... you want call mapkey by clicking F2 key instead of clicking dd1 key combination. If this is the case then simply change config.pro line using Notepad.

mapkey dd1 @SYSTEMstart C:\\PTC\\CSYS_rename_CR3_prvek4\\rename_csys_prt.exe;

to

mapkey $F2 @SYSTEMstart C:\\PTC\\CSYS_rename_CR3_prvek4\\rename_csys_prt.exe;

MH


Martin Hanák

Re: How to assign model name to default CSYS

I think he was looking at the .au3 source code which calls the F2 key

Re: How to assign model name to default CSYS

This method will rename the csys to match the part number only or will it automatically match the csys name when I create a new part?

Re: How to assign model name to default CSYS

Hi,

the mapkey renames coordinate system (feature no.4) in model tree.

MH


Martin Hanák

Re: How to assign model name to default CSYS

Short video showing dd1 and dd2​ results.


Martin Hanák

Re: How to assign model name to default CSYS

Not useful solution

Re: How to assign model name to default CSYS

Not useful solution

Re: How to assign model name to default CSYS

In Tcl I need one Line of code for this:

 

ps_feat set_name [lindex [ps_visit type csys] 0] [file root [ps_model cur]]

 

Next a procedure, which is more save:

 

FirstCsysNameToModelName.png

 

Here a movie ... 

 

 

Re: How to assign model name to default CSYS

Not a usable solution.

Re: How to assign model name to default CSYS

You are almost right, but p-Shell is running in a SandBox, you need to copy one folder only.

pEnv.png

The "PNG" shows the env, the movie shows what happen if you add a new folder to your SandBox programs.

 

  1. Start the Csys app,
  2. keep it running,
  3. do the source code edit
  4. Source the edited file again
  5. Run the newly created button

This is not a final app, but should show how easy it is to make an update or test new code.

 

 

Note: This Tcl program run in synchronous mode.

Cheers

Re: How to assign model name to default CSYS

Does p-Shell ship from PTC?

Re: How to assign model name to default CSYS

Ha, as I guess you work for PTC, and this is not from PTC Smiley Very Happy

Re: How to assign model name to default CSYS

If I worked for PTC then I would have a PTC badge.

Feel free to link to the source.

Re: How to assign model name to default CSYS

Use the mail address from the Wiki to get more information.

 

Re: How to assign model name to default CSYS

100 Kudos for this statement Smiley Very Happy

Re: How to assign model name to default CSYS

functionality can be customized by toolkit for open/rename/saveas/import

Announcements