Menu item Action to push button in form

Hi, I’m almost ready to accept the fact, that I can’t use function keys within a form… but before I give up for good: My goal is to run the code behind “TB” when I press F9. This code needs the current line of the table box in the background. The code will open a form that depends on the content of the line. Alas, the users have to navigate within the table box so writing a visual basic keyboard catching dll won’t help. I can catch the F9 key with the menu item “M_I”. This doesn’t allow me to start any code within the form. Correct me, if I’m wrong but as far as I understand it, the RunObject Action can’t pass on any values. Can any other of the actions offered here access code within the form? I have some hopes for RunSystem, but it only opens a DOS window and I see no way of (for example) putting code behind it to put the ALT-combination for the button into the keyboard buffer.

If you don’t put in any action, you can put code behind the test option on the MI button. You would have to duplicate the TB code, but it should work fine.

quote:

If you don’t put in any action, you can put code behind the test option on the MI button. You would have to duplicate the TB code, but it should work fine.

This is probably a dumb question, but how do I find the test option? (I’m using Attain 3.70 here) The C/AL-Code of the button only has “OnActivate” and “OnDeactivate” which both don’t get run if I press the keyboard shortcut.

Sorry for interrupting Chris, don’t want to interfere but considering the time lag between Germany and Canada… mborus: what Chris means is that when you don’t put any action behind the “test” line in your example, you can enter C/AL code behind the line so to speak. So hit F9 when you’ve got the menu line selected and write your code in the OnPush trigger. Hitting F9 when you have the button itself selected yields the result you mentioned (Activate / Deactivate triggers). Hope this helps

quote:

So hit F9 when you’ve got the menu line selected and write your code in the OnPush trigger.

Thanks, this is what I’m was looking for.