Discussion:
Using Right click by code
(too old to reply)
Guillaume Paquette
2011-04-05 09:24:58 UTC
Permalink
Hi,

I need to add a fonction by using right click on a field.

How can I do that? What fonction should I use?

Thanks by advance,

Guillaume
Guillaume Paquette
2011-04-08 09:12:00 UTC
Permalink
Thx to Seb for the solution :

On the form field :

public int showContextMenu(int _menuHandle)
{
int ret;
PopupMenu _menu = PopupMenu::create(_menuHandle,this.hWnd());

int myMenuItem = _menu.insertItem("Seb est un CADOR");
int myMenuItem2 = _menu.insertItem("Seb est un MEGA CADOR");
;
ret = _menu.draw();

switch (ret)
{
case -1:
break;

case myMenuItem:
if (GPLInterfaceIoTable.RepertoireTravail)

WinAPI::shellExecute('explorer.exe',GPLInterfaceIoTable.RepertoireTravail,'','',
1);
break;

case myMenuItem2:
info("tt");
break;
}

return ret;
}
Post by Guillaume Paquette
Hi,
I need to add a fonction by using right click on a field.
How can I do that? What fonction should I use?
Thanks by advance,
Guillaume
Loading...