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

Copy parameter in Mapkey won't work after re-booting Creo

Highlighted
Marble

Copy parameter in Mapkey won't work after re-booting Creo

Hello,

I have tried to record a Mapkey in which I want to copy a specific parameter of a selected component in a assembly. The steps are:

-> right mouse click

-> Edit Parameters

-> left mouse clik on the wanted parameter value

-> Edit menu

-> Copy

-> close parameters window

Here below a video of the mapkey record:

Video Link : 6854

The Mapkey works if I run it in the session where it has been recorded, with other components and other assemblies too, but doesn't work when I restart (after having saved it obviously) Creo, as if there is something in the recording related to a specific session (but that I can't see from the config.pro). (Also, the parameter whose to copy the value is present is every assembly and part we have).

Anyone can tell what is it due to and if there is something I can modify in the mapkey config.pro code to make it working forever?

(Here below the code I recorded (where codice_disegno is the parameter name):

mapkey 7 ~ Timer `UI Desktop` `UI Desktop` `popupMenuRMBTimerCB`;\

mapkey(continued) ~ Close `rmb_popup` `PopupMenu`;~ Activate `rmb_popup` `EditParameters`;\

mapkey(continued) ~ Arm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

mapkey(continued) ~ Disarm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

mapkey(continued) ~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\

mapkey(continued) ~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBCopy`;\

mapkey(continued) ~ Close `relation_dlg` `relation_dlg`;

(I am trying to record this mapkey to then use it to open a selected component drawing with the help of an external software and it would be much more useful to have the copy value inside Creo).

thanks

Tommaso

40 REPLIES 40
Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

if i want to select a specific parameter i dont select it but use the search function in the parameter window.

If you da a search it selects the parameter you want and you can continue with the rest of the mapkey.

I found it to be difficult to consistently select the right parameter.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Hans,

thanks for your reply. Indeed it can be a way. How can I tell the program to select and copy the value after the search? (what code string I should insert).

Because If I select the value with the mouse click, it falls back to the situation of my original mapkey and it won't work at next sessions...

Thanks

Greetings

Tommaso

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

What i would  do:

-model intent

-parameters

-edit

-find

-enter parameter name you need to find "CODICE_DISEGNO"

-add

-find

-close

// it now selected your parameter name

- 2x right arrow button

// now you have your value selected

-edit

-copy

Hope this helps for you.

Isnt it beter to use your external software ( jlink,Web.link) to read out the open model and open its drawing?

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Thanks.I have tried your solution, the problem is that for some parts the first selected (cyan color) parameter in the parameters window at opening is CODICE_DISEGNO itself, while for other parts it's another parameter

-> therefore if I record the mapkey in the former case, after clicking FIND, since the CODICE_DISEGNO is already in cyan the software asks me if I want to repeat the search from top (video below):

Video Link : 6857

Instead, if I record it in the latter case, no re-search confirmation request appears (the parameters is found and is highlighted in cyan).

This problem makes either mapkey uncompatible in the other case unluckily...

This same difference wouldn't allow also to directly press 2x right arrow, since for parts without CODICE_DISEGNO highlighted by default, the mapkey will copy the value of another parameter...

Bye

Tommaso

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hello Tommaso,

still having this problem?

Did you try to run the mapkey on the other assembly?

Because when a mapkey encounters a problem it just continues .

So in your example it will try to press yes (on the question to start again from the top). if this button isn't available it will pretend to press it and give a warning in the message window and then just go on with the rest of the mapkey.

I tried it on my system and it works oke.

The only thing is you have to make sure the parameter "CODICE_DISEGNO" exists in every part.

so just record the mapkey with "CODICE_DISEGNO" selected as default.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Hans,

thanks for your reply.

Yes I have tried to perform the mapkey on another assembly after having saved it and then rebooted Creo but it doesn't work, as if something of the mapkey record is tied to the Creo session itself. I don't know why, I also watched the mapkey code and there isn't anything that seems specific of the session itself.

I made sure also that the parameter "CODICE_DISEGNO" exists in every part obviously.

Could you post your mapkey code so that I can make a comparison?

Thanks

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

I think, in fact, do you want to add specific parameters to the parts?

If so, the fastest way is to use modelcheck

Menu - -modelcheck-modelcheck-Analysis interractive-all levels-enter

It will check if you have the parameters you need, if not, it can automatically help you write to the parts, of course, this must go through the configuration of the config file.

here:

D:\Program Files\proeWildfire 5.0\modchk\text\usascii\config\check-create a file (like:0.mch)

&

D:\Program Files\proeWildfire 5.0\modchk\text\usascii\config\start-create a file (like:0.mcs)

Use Notepad to open it

To be continued...

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hello Chenwei,

Thanks for your reply. Indeed I don't need to add parameters to the parts, in fact all the CAD stored in our system already have the parameter I need for running the mapkey, and the problem in my case is that the mapkey recorded isn't working in Creo sessions other than the one where I recorded the mapkey itself...

Bye

Tommaso

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Unable to copy the current value.

In this case we are trying to use the shortcut key to achieve the DRW name = PRT name consistent, already know.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Chen,

thanks for your reply.

I am not sure about what you mean (Just to know, are you using the translator?), so I will try to answer you like I got it:

Yes, indeed what I am trying to achieve is to make a mapkey that copies an assembly part name (which is stored in the part parameter codice_disegno), inside Creo, in order to then paste that value in the file open window and open its drw (our drws have the same file name as their respective parts, except for the extension obviously).

(This is a quite common discussion perpetrated in other topics, and solved also (with External scripts)).

it's a pity that this little issue it's blocking the solution.

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

yes!

I am a bad boy, never a good study, so now I can‘t speak English, read and write more bad!

If the shortcut key also needs to be suspended, it is not fast. PTC is squeezing toothpaste, and slowly.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

No problem, I was just asking because the translation seemed a bit strange. Yes in fact the purpose Is to make it directly inside Creo, without recalling external programs.

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Perhaps an easier way you can try is to export the parameter info to a file and then have the external software extract the value of the parameter directly from this file...

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Paul,

thanks for your reply, yes indeed that could be a way. However for the usage I have to do of it in my case (open drw mapkey as wrote to Chen), I have already found a solution with an external Autohotkey script recalled by a mapkey, and instead by using this technique of copying the parameter value remaining inside Creo would allow to avoid external sourcing thus speeding up the mapkey execution...(and maybe also its stability in case other programs windows pop up suddenly, as Windwos updatings or Outlook messages).

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

I find that mapkeys that use the "Timer" commands or that rely on the right-mouse button menu, don't work reliably when session is restarted.  The code below avoids this issue by using the ProCmd... like commands to get the parameter ui to show up for the component in question.

Try this mapkey, it seems to work for me:

mapkey 99 @MAPKEY_LABELGet_CODICE_DISEGNO (99);\

~ Command `ProCmdMakeActive`;\

~ Command `ProCmdMmParams` ;\

~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\

~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBSearch`;\

~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` \

`CODICE_DISEGNO`;~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

~ Activate `param_search` `PrmSearchFindPush`;\

~ Activate `0_std_confirm` `OK`;\

~ Activate `param_search` `PrmSearchClosePush`;\

~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\

~ Arm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\

~ Disarm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\

~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\

~ Arm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

~ Disarm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\

~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBCopy`;\

~ Close `relation_dlg` `relation_dlg`;

how to use:

select the component in the assembly.

press 99

- the text in the model's parameter "CODICE_DISEGNO" is copied to the clipboard.

Note: works whether the parameter "CODICE_DISEGNO" is 1st in the list or not - using the Find functionality as described elsewhere in this thread

Note: component remains as the "active model".

Perhaps you can adapt this further to your needs...

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Thanks for you reply.  Yes I noticed too the unreliability of using the timer and the right mouse button, especially the latter when you right click on a table or on a list, it records the "node" where the pointer is, making it unusable in assemblies other than the one where you recorded it.

This script unfortunately doesn't work in my version, I would need to read the trailfile to investigate more.

My initial idea was to open the assembly component parameters window directly from the assembly itself, with the right click on the graphic area (or on the component located in the model tree):

1.PNG

that in the mapkey is recorded with the command Activate 'main_dlg_cur' 'Edit Parameters'.

I hade already made a temporary mapkey which uses, as you did, the component activate command+ autohotkey script, and which I will post here in this topic for anyone who may be interested as an alternative to use a VB Script, Web.Link or JLink app.( It's temporary because I am trying to do it entirely in Creo, as told).

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

This is my try, not much different, but used Ctrl+F to find the parameter. Maybe this way it can be more consistent:

mapkey 7 ~ Command `ProCmdEditParameters@PopupMenuGraphicWinStack` ;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 38141958 `Ctrl+F`;\

mapkey(continued) ~ Activate `relation_dlg` `PBSearch`;\

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\

mapkey(continued) ~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` \

mapkey(continued) `CODICE_DISEGNO`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 37945347 `Ctrl+C`;\

mapkey(continued) ~ Activate `relation_dlg` `PB_OK`;

Also, if your mapkey doesn't work, stop and inspect your trailfile to see what is causing the failure.

Jose

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hmm, that one doesn't work for me (Creo 2, M210).


But I did manage to simplify my mapkey:

mapkey 99 @MAPKEY_LABELGet_CODICE_DISEGNO (99);\

~ Command `ProCmdMakeActive`;\

~ Command `ProCmdMmParams` ;\

~ Activate `relation_dlg` `PBSearch`;\

~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` \

`CODICE_DISEGNO`;~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

~ Activate `param_search` `PrmSearchFindPush`;\

~ Activate `0_std_confirm` `OK`;\

~ Activate `param_search` `PrmSearchClosePush`;\

~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

~ Activate `relation_dlg` `PBCopy`;\

~ Close `relation_dlg` `relation_dlg`;\

~ Command `ProCmdWinActivate`;

I'm curious how the OP then uses mapkey commands to open the drawing named according to the string now in the clipboard...

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

I tried with this last script but it doesn't work either unfornutately. In the execution, I don't see anything on the screen as if not even the first step is done.

Concerning the paste action in the open model, yes it's a major problem and for it I had thought I could eventually run an external program for these two last short steps (paste+middle mouse button), which is not the desired solution but would speed up the execution time and also improve the reliability: obviously being able to do it still in Creo would be perfect.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Thanks for your reply. I tried your version too but it doesn't work in my version, I am trying to understand why and for this it would be useful to see the trailfile you mentioned...where can I find it?

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Examine the trail.txt.xxx file that creo continually updates as you are working in a session.

the trail files are usually put in the starting directory, unless you specify another one with config.pro option trail_dir.

This is the sample output from my session:

!trail file version No. 1600

!Creo  TM  2.0  (c) 2016 by PTC Inc.  All Rights Reserved.

!Exit Logger data:

!    Process ID: 8108

!    Application: Creo_Parametric

!    Start date&time: 2016/05/25  08:01:38

!    language: usascii

!    machine type: x86e_win64

!    datecode: M210

!    Server: NONE

!    Workspace: NONE

!    traceback file: e:\Prowork_Creo2\traceback.log

...

...

...

!%CIShowing part SEW_WF20DRS71S6.

>M Collectors_CB ProeWin0 1538 190 100c0 0 1629 0 0 753 1920 0 0 1080 13

!playing mapkey 99

~ Command `ProCmdMakeActive`

~ Command `ProCmdMmParams`

~ Activate `relation_dlg` `PBSearch`

~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`

~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`

~ Activate `param_search` `PrmSearchFindPush`

~ Activate `param_search` `PrmSearchClosePush`

~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`

~ Activate `relation_dlg` `PBCopy`

~ Close `relation_dlg` `relation_dlg`

~ Command `ProCmdWinActivate`

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Paul,

thanks for the instructions. I report here below the mapkeys proposed in this topic and the trail file recorded when played:

Mapkeys (reporting the author's name and post date):

mapkey test1 @MAPKEY_LABELGet_CODICE_DISEGNO (9);\ 

mapkey(continued) ~ Command `ProCmdMakeActive`;\ 

mapkey(continued) ~ Command `ProCmdMmParams`;\

mapkey(continued) ~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\ 

mapkey(continued) ~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBSearch`;\ 

mapkey(continued) ~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\ 

mapkey(continued) ~ Activate `0_std_confirm` `OK`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\ 

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\ 

mapkey(continued) ~ Arm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\ 

mapkey(continued) ~ Disarm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\ 

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `type`;\ 

mapkey(continued) ~ Arm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\ 

mapkey(continued) ~ Disarm `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\ 

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\ 

mapkey(continued) ~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\ 

mapkey(continued) ~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBCopy`;\ 

mapkey(continued) ~ Close `relation_dlg` `relation_dlg`; 

mapkey test2 ~ Command `ProCmdEditParameters@PopupMenuGraphicWinStack` 

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 38141958 `Ctrl+F`;\ 

mapkey(continued) ~ Activate `relation_dlg` `PBSearch`;\ 

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\ 

mapkey(continued) ~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`;\ 

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu`;\ 

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\ 

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\ 

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\ 

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\ 

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 37945347 `Ctrl+C`;\ 

mapkey(continued) ~ Activate `relation_dlg` `PB_OK`; 

mapkey test3 @MAPKEY_LABELGet_CODICE_DISEGNO (99);\ 

mapkey(continued) ~ Command `ProCmdMakeActive`;\ 

mapkey(continued) ~ Command `ProCmdMmParams`;\

mapkey(continued) ~ Activate `relation_dlg` `PBSearch`;\ 

mapkey(continued) ~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\ 

mapkey(continued) ~ Activate `0_std_confirm` `OK`;\ 

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\ 

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\ 

mapkey(continued) ~ Activate `relation_dlg` `PBCopy`;\ 

mapkey(continued) ~ Close `relation_dlg` `relation_dlg`;\ 

mapkey(continued) ~ Command `ProCmdWinActivate`; 

mapkey test4 ~ Command `ProCmdEditParameters`;\ 

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\ 

mapkey(continued) ~ Activate `relation_dlg` `PBCopy`;~ Activate `relation_dlg` `PB_OK`; 

(with "search from the top again" question included)

mapkey test5 ~ Timer `UI Desktop` `UI Desktop` `popupMenuRMBTimerCB`;\

mapkey(continued) ~ Close `rmb_popup` `PopupMenu`;~ Activate `rmb_popup` `EditParameters`;\

mapkey(continued) ~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\

mapkey(continued) ~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBSearch`;\

mapkey(continued) ~ Open `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu`;\

mapkey(continued) ~ Close `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu`;\

mapkey(continued) ~ Select `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` 1 \

mapkey(continued) `CODICE_DISEGNO`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\

mapkey(continued) ~ Activate `0_std_confirm` `Cancel`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\

mapkey(continued) ~ FocusIn `relation_dlg` `ParamsPHLay.ParTable`;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\

mapkey(continued) ~ Key `relation_dlg` `ParamsPHLay.ParTable` 589833 `Tab`;\

mapkey(continued) ~ Select `relation_dlg` `MenuBar1` 1 `Edit`;\

mapkey(continued) ~ Close `relation_dlg` `MenuBar1`;~ Activate `relation_dlg` `PBCopy`;\

mapkey(continued) ~ Close `relation_dlg` `relation_dlg`;

Trail file (from the moment I click on upper right corner search bar till its closing after running the 5 mapkeys):

~ Command `AdbCmdSearchCommand`  1

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test1`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test1`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test1`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test1`

!playing mapkey test1

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test2`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test2`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test2`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test2`

!playing mapkey test2

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test3`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test3`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test3`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test3`

!playing mapkey test3

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test4`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test4`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test4`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test4`

!playing mapkey test4

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test5`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test5`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test5`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test5`

!playing mapkey test5

~ Timer `UI Desktop` `UI Desktop` `popupMenuRMBTimerCB`

~ Close `rmb_popup` `PopupMenu`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

~ Close `main_dlg_cur` `main_dlg_cur`

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Your trail file reveals that the mapkeys test1 - test5 are not being executed...

One thing to try is to reduce the # of characters in some of your lines; for instance, the line 5 in your mapkey test3 seems too long:

mapkey test3 @MAPKEY_LABELGet_CODICE_DISEGNO (99);\

mapkey(continued) ~ Command `ProCmdMakeActive`;\

mapkey(continued) ~ Command `ProCmdMmParams`;\

mapkey(continued) ~ Activate `relation_dlg` `PBSearch`;\

mapkey(continued) ~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`;\

mapkey(continued) ~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchFindPush`;\

mapkey(continued) ~ Activate `0_std_confirm` `OK`;\

mapkey(continued) ~ Activate `param_search` `PrmSearchClosePush`;\

mapkey(continued) ~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

mapkey(continued) ~ Activate `relation_dlg` `PBCopy`;\

mapkey(continued) ~ Close `relation_dlg` `relation_dlg`;\

mapkey(continued) ~ Command `ProCmdWinActivate`;

try deleting all mapkeys in your config.pro and only have this one:

mapkey test3 @MAPKEY_LABELGet_CODICE_DISEGNO (test3);\

~ Command `ProCmdMakeActive`;\

~ Command `ProCmdMmParams`;\

~ Activate `relation_dlg` `PBSearch`;\

~ Update `param_search` `PrmFilterPHLay.FilterRuleValueOptEditableMenu` `CODICE_DISEGNO`;\

~ Activate `param_search` `PrmFilterPHLay.FilterRuleAddPush`;\

~ Activate `param_search` `PrmSearchFindPush`;\

~ Activate `0_std_confirm` `OK`;\

~ Activate `param_search` `PrmSearchClosePush`;\

~ Select `relation_dlg` `ParamsPHLay.ParTable` 2 `rowCODICE_DISEGNO` `value`;\

~ Activate `relation_dlg` `PBCopy`;\

~ Close `relation_dlg` `relation_dlg`;\

~ Command `ProCmdWinActivate`;

you don't need to have the mapkey(continued) statement, so get rid of it to give yourself more room.

In my experience, there is a limit as to how many characters can be in config.pro file line.

You can split your lines if you need to exceed it with the \

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Paul,

thanks for your tips. I wasn't thinking long rows may be a problem, also because Creo itself often records mapkeys with many subsequent commands (and the mapkey(continue) too).

The tip that the mapkey(continue) isn't necessary is a good point, I didn't know it and indeed it is more comfortable without in editing mapkeys.

I tried your simplified code but the mapkey still doesn't run...seems not to even start. Here the trail:

~ Command `AdbCmdSearchCommand`  1

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `t`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `te`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `tes`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test`

~ Input `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test6`

~ Update `main_dlg_cur` `search_panel_pholder.search_panel_input_panel` `test6`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `` `Mapkeys_not_in_rbn_group`

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` `test6`

~ Select `search_panel_list_of_main_dlg_w1` `search_panel_list` 1 `test6`

!playing mapkey test6

~ Trigger `search_panel_list_of_main_dlg_w1` `search_panel_list` ``

The same thing now that I remember, happened to a mapkey created for making the replace of a component...in other sessions other than the original of the recording, doesn't work at all.

Bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

One more time - Open the Mapkey window, select a mapkey that should work but doesn't, then click on RUN. Then pick a mapkey that -does- work and click RUN. Then show what they look like in the trail file. Don't type the mapkey - RUN them from the Mapkey window.

As far as the trail you posted, doesn't the message seem odd to you? "Mapkeys_not_in_rbn_group"?  It looks as if Creo can't find the mapkey, but since they are in memory, Creo can't avoid finding it. Why would Creo search to find a mapkey?

The only other thing that occurs to me is that at least one mapkey is in your config.sup and this interferes with any mapkey from working.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi David, I had already tried to run some mapkeys in the same session, some of them work, some others don't, otherwise that would have raised more than one question in me, and also from the mapkey window. (in that "others"  I wrote, all the tests here listed are included, + another one I had recorded for replacing components: in sessions other than that where it's been recorded in, doesn't start at all).

As far as the trail file I posted, yes, It definitely looks strange to me the message "Mapkeys_not_in_rbn_group", but I don't know what it means, nor I found anything on the internet (the only google result is the current post ), I was hoping that someone has already experieced that.

Anyway, here below the trail file for a working mapkey (a save & upload ), + the not working "test6" (run after clicking on a component obviously) both run in the same session and from the mapkey window:

!%CIPlaying mapkey s...

!playing mapkey s

~ Command `ProCmdViewDefault`

~ Close `main_dlg_cur` `appl_casc`

~ Command `ProCmdModelSaveToWindchill`

!%CIAutomatic regeneration of the parts has been completed.

~ Activate `file_saveas` `OK`

!%CI150616 has been saved.

!%CIUpload started: 150616.ASM.

!%CIUpload succeeded: 150616.ASM. See the Event Management console for details.

~ Move `main_dlg_cur` `proe_win` 9 1319 313 67108864 0 1540 911 1920 1200 55337

~ Activate `mapkey_main` `mapkey_main`

~ LButtonArm `main_dlg_cur` `proe_win` 9 903 433 0 1 1540 911 1920 1200 57508

~ LButtonDisarm `main_dlg_cur` `proe_win` 9 903 433 0 0 1540 911 1920 1200 57603

@ sel view 0

0.919095 -0.304391 -0.241550 0.000000 0.620283 -0.781655

0.388587 0.719952 0.571319 749.547331 137.164898 -2368.703848 1.000000 0.000000 0

@ stack idx 0

@SELECTION 1 1 3628 69 -1 -1 25.9581554435 458.8885850995 40.8885850995 0.9581554435 -25.0000000000

~ Select `mapkey_main` `list_mapkeys` 1 `test6`

~ Activate `mapkey_main` `RunButton`

!%CIPlaying mapkey test6...

!playing mapkey test6

There is no trace of the "Mapkeys_not_in_rbn_group" in this case (maybe it's because it's played from mapkey window).

For the "test6", after having clicked on run, the lower left message remains "playing mapkey test6...", and doesn't happen anything on the screen, (nor it copies the involved parameter).

I searched in my PC disk for the config.sup you mentioned and there isn't. Also, I found another community discussion on it involving mapkeys:

config.sup vs .pro

maybe it gives some more indications, I will read it.

bye

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

For me, the "Mapkeys_not_in_rbn_group" message shows up in the trail file if I type in the mapkey into the command-search box in the ribbon.  The trail file shows what happens as you type in each letter and when the drop-down box shows up with a section in it about "commands not in the ribbon".  Note that the mapkey in question (test3 or test6) still worked fine for me when started with this method.

One thing I notice is that your trailfile doesn't show the action of picking a component (not that it should matter - if you didn't pick a component, then the mapkey should copy to clipboard the value of parameter "CODICE_DISEGNO" of the currently active model or assembly.)

Maybe because you don't have the config.pro option provide_pick_message_always yes

Anyway, this is quite baffling; did you try a session with a config.pro that only has the test6 mapkey defined in it?

It seems to me that there is an error in the mapkeys somewhere and test6 has invalid commands in it because of it.  This could be anything - the character ' used instead of `, or a missing \ or ; somewhere, or something like it that is hard to diagnose without seeing your config.pro.

Good luck!

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Thanks for the info. I have never used the command search box and would not use it for mapkeys, so I would otherwise not come across it.

It's weird. I started with ComputerVision where all commands were typed, though they had the tablet that made 'mapkeys' really easy. Then came the menu era, the pictographic icon era, and now the big advance is typing commands in again. Not bad for a 30 year loop.

Highlighted

Re: Copy parameter in Mapkey won't work after re-booting Creo

Hi Paul,

yes the component is already selected before running the mapkey (as wanted for the mapkey itself), the fact that isn't in the trail file is because I copied the trail part from the mapkey execution moment. I have some other mapkeys working perfectly with already selected component (f.e., open selected assembly component).

I also just tried to run a session with just that mapkey on, but with no difference at all, it doesn't start and the lower left message is still the same (playing mapkey test6...).

The test6 has been recorded directly in Creo, and not edited at all by me, so it shouldn't have errors in the punctuations...

thanks

bye

Announcements