Simulating right click and selection from context menu

Doug Easterbrook doug at artsman.com
Thu Dec 29 09:41:25 EST 2016


hi Greg:

I’m assuming you are talking studio, not the javascript client.

there is a $contextMenu property on all fields and on the complex grid control itself that you can attache a menu to — then it works as a context menu with programming on your part.

or in one of the ‘ev' methods like evclick — use popupmenu from list or popup menu   (popup menu can get you to open any of the menus that you’ve got in your application

or, if you want, use owrites popup menu to make hierarchical menus if you need them



on the other hand, in reading your note…..   it could seem like you don’t want the menu, just to execute an action within the menu.

if you just want to excute code that is in the menu, I’d take it out of the menu and call it directly.     within the menu, you can also call the code.

eg.
in our menus, we typically have something like      do   windowref.$doBtnYYYYY

and $doBtnYYYYY is in the window so that the function can be called from popup menu, toolbar menu, button on the screen or via a simple method call if we want.


not sure if thats what you are after.








Doug Easterbrook
Arts Management Systems Ltd.
mailto:doug at artsman.com
http://www.artsman.com
Phone (403) 650-1978

> On Dec 29, 2016, at 7:23 AM, Grzegorz (Greg) Pasternak <grzegorz at niagara.com> wrote:
> 
> I need to simulate user action to pop up context menu from the list in grid control following by selection of the menu item.
> 
> I have tried following to open context menu:
> 
> Queue set current field {[pRow.cFldName]}
> Queue click (Shift,Command/Ctrl) {[pRow.cFldName] (pRow.cLineNo)}
> 
> where pRow is parameter passed to this method.
> 
> No luck so far.
> 
> What else can I try?
> 
> Greg
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com




More information about the omnisdev-en mailing list