I'd like to have a right-click popup menu in an XPage. I therefore created a popup menu in XPages using the Extension Library. The menu doesn't display, whatever I try. Do I have to bind it to a button or so? If so, how??
Asked
Active
Viewed 1,068 times
2
-
If you want to use your xpage in client (XPiNC), right-click wont work. – Frantisek Kossuth May 23 '12 at 15:09
2 Answers
5
Yes, it needs to be bound to a link or a button. The button or link needs to use Client-Side JavaScript to call the xe:popupMenu. There is an example in the Extension Library demo database, or more information in the XPages Extension Library book, chapter 8, p252.

Paul Stephen Withers
- 15,699
- 1
- 15
- 33
-
Have neither book nor demo db. Correction: I have the demo db somewhere, but I was too lazy to go on a fishing expedition in the demo db... *sigh* I'll get my tackle... – D.Bugger May 22 '12 at 16:55
-
1Here's a link to the demo in OpenNTF hosted version of the Extension Library database: http://208.85.190.65/demos/demoextlib.nsf/Core_Outline.xsp – Per Henrik Lausten May 22 '12 at 17:58
-
0
<xp:eventHandler event="contextmenu" submit="false">
<xp:this.script><![CDATA[XSP.openMenu(thisEvent,#{javascript:getComponent('pop1').getMenuCtor()})
]]></xp:this.script>
</xp:eventHandler>

Thomas Adrian
- 3,543
- 6
- 32
- 62