Jump to content

TUniPopupMenu problem


roman.attila

Recommended Posts

Hi all,

 

I would like to implement a popupmenu in dbgrid. I'm using containercontextmenu event of grid for popup and I need the JSName's value of popupmenu. In runtime in Form.Loaded method the JSName of TUniPopupMenu is empty. How can I get a real name of popupmenu in javascript?

 

Example:

 

function containercontextmenu(sender, e, eOpts)
{
  var position = e.getXY();
  e.stopEvent();
  O3B.showAt(position);
}

 

O3B is name of popupmenu

 

UniGUI version: 0.94 build 1024

Delphi 2010

 

Thanks,

Attila

Link to comment
Share on other sites

How can I get a real name of popupmenu in javascript?

 

Hi Román Attila.  
 
I think maybe it's not the best solution, but, gives the result ...
 
In javascript:
MainForm.CreateButton1.parentMenu.id;

CreateButton1 - one of your UniMenuItem UniPopupMenu.

 

For example: 

MainForm.CreateButton1.parentMenu.showAt(10, 10);

post-906-0-11243600-1391172325_thumb.png

 

 

Best regards

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...