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

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

Open generic instance from instance with mapkey

GunnarHansen
1-Visitor

Open generic instance from instance with mapkey

Use the record option for mapkeys (tools, mapkey): Having the instance open pick: File, new, drawing, ect.. Name the drawing with copy/paste: "to-be-deleted" The drawing-model will default be the instance in question. Now replace instance to generic: File, properties, drawingmodel, replace, etc... Default will generic be chosen. just finish the replace command. Now open enter enter to default open the drawing model File, Open, enter, enter. Now we just need to erase the temporary drawing:"to-be-deleted.drw": File, Open, "to-be-deleted.drw", File Erase, Current, yes... In config.pro it looks like this, but better record yourself: mapkey rg @MAPKEY_LABELretreive generic;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;~ Activate `main_dlg_cur` `File.psh_new`;\ mapkey(continued) ~ Select `new` `Type`1 `Drawing`;~ Input `new` `InputPanel1` ;\ mapkey(continued) ~ Input `new` `InputPanel1` `to-be-deleted`;\ mapkey(continued) ~ Update `new` `InputPanel1` `to-be-deleted`;\ mapkey(continued) ~ Activate `new` `chk_use_default_template`0 ;~ Activate `new` `OK`;\ mapkey(continued) ~ FocusIn `dwg_create` `inp_model_name`;~ Activate `dwg_create` `psh_ok`;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;\ mapkey(continued) ~ Activate `main_dlg_cur` `File.psh_properties`;#DRAWING MODELS;#REPLACE;\ mapkey(continued) ~ Activate `open_instance` `open`;#DONE/RETURN;\ mapkey(continued) ~ Activate `main_dlg_cur` `ProCmdModelOpen.file`;\ mapkey(continued) ~ Activate `file_open` `Inputname`;\ mapkey(continued) ~ Activate `open_instance` `instnamelist1`1 `the generic`;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;~ Activate `main_dlg_cur` `File.psh_open`;\ mapkey(continued) ~ Input `file_open` `Inputname` `TO-BE-DELETED.DRW`;\ mapkey(continued) ~ Update `file_open` `Inputname` `TO-BE-DELETED.DRW`;\ mapkey(continued) ~ Activate `file_open` `Open`;~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Select `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;\ mapkey(continued) ~ Close `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Activate `main_dlg_cur` `psh_erase`;~ Activate `0_std_confirm` `OK`; See also http://ww3.cad.de/foren/ubb/Forum12/HTML/010934.shtml
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.
3 REPLIES 3

Now the mapkey rg works also from generic and different other config.pro settings. Have a try, please. mapkey rg @MAPKEY_LABELretreive generic;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;~ Activate `main_dlg_cur` `File.psh_new`;\ mapkey(continued) ~ Select `new` `Type`1 `Drawing`;~ Input `new` `InputPanel1` `to_be_deleted`;\ mapkey(continued) ~ Update `new` `InputPanel1` `to_be_deleted`;\ mapkey(continued) ~ Activate `new` `chk_use_default_template`0 ;~ Activate `new` `OK`;\ mapkey(continued) ~ FocusIn `UI Message Dialog` `ok`;~ Activate `UI Message Dialog` `ok`;\ mapkey(continued) ~ FocusIn `dwg_create` `inp_model_name`;~ Activate `dwg_create` `psh_ok`;\ mapkey(continued) ~ Activate `open_instance` `open`;~ Activate `open_rep` `OK`;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;\ mapkey(continued) ~ Activate `main_dlg_cur` `File.psh_properties`;#DRAWING MODELS;#REPLACE;\ mapkey(continued) ~ Activate `open_instance` `open`;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;~ Activate `main_dlg_cur` `File.psh_open`;\ mapkey(continued) ~ Activate `file_open` `Inputname`;\ mapkey(continued) ~ Activate `open_instance` `instnamelist1`1 `the generic`;\ mapkey(continued) ~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;~ Activate `main_dlg_cur` `File.psh_open`;\ mapkey(continued) ~ Input `file_open` `Inputname` `to_be_deleted`;\ mapkey(continued) ~ Update `file_open` `Inputname` `to_be_deleted`;~ Activate `file_open` `Open`;\ mapkey(continued) ~ Activate `open_rep` `OK`;~ Select `main_dlg_cur` `MenuBar1`1 `File`;\ mapkey(continued) ~ Select `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Close `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Select `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Close `main_dlg_cur` `MenuBar1`;\ mapkey(continued) ~ Close `main_dlg_cur` `File.cb_file_erase`;\ mapkey(continued) ~ Activate `main_dlg_cur` `psh_erase`;~ Activate `0_std_confirm` `OK`;

In Wildfire 5 this is a (finally!) standard function. Select the instance part > Right mouse button > Open Generic.

Has anybody tried it out? Or are you all on WF5 already.
Announcements
NEW Creo+ Topics: PTC Control Center and Creo+ Portal


Top Tags