-
We are adding the custom menu in lotus notes client menu bar and tool bar.
-
When the view is opened for first time, the menu items are disabled in disabled state.
-
After selecting any documents, then menus are enabling correctly.
Please help me to resolve this issue.
Subject: please provide more detail.
And please use precise terminology. You can’t add a menu to the tool bar because the tool bar doesn’t contain menus. Are you talking about actions? What exactly do you mean they’re “disabled”? Show your code. Etcetera.
- Andre Guirard, IBM/Lotus Development
Useful blog: Best Practice Makes Perfect
NOTE: My policy is to post only two responses to the same question. So that my second response can solve your problem rather than being a request for details, please read the C R I S P Y document.
Subject: Reg : Menu items are disabling in lotus note client.
Hi Andre Guirard,
Thanks for your reply.
I added my custom menu in Lotus Notes Client 8.0 menu bar using PlugIn.xml file, not in toolbar.
then i tried to disable the menu in “selection changed” event.
Code used inside selectionChanged Event:
action.setEnabled(false);
after clicking on the menu button it shows “Choosen operation is currently disabled”. then menu become to disabled state.
after i am able to enable the same menu in “Selection Changed” event. it’s working fine.
but first time when i am disabling the menu item, but it shows the “Choosen operation is currently disabled” error message then menu gets disabled.
my PlugIn.xml file content as below.
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.2"?>
<extension
point="org.eclipse.ui.actionSets">
<actionSet
id="com.ibm.notes.mail.utils.actionSet"
label="Mail Tools">
<action
class="Menu1"
icon="icons/Menu1.gif"
id="Menu1"
label="Menu1"
style="push"
tooltip="Menu1"
toolbarPath="actions/additions">
</action>
</actionSet>
<actionSet
id="link"
label="link">
<menu
id="linkmenu"
label="&MyMenu"
path="window">
<separator
name="linksep">
</separator>
<separator
name="linksep2">
</separator>
</menu>
<action
class="Menu1"
icon="icons/Menu1.gif"
id="Menu1"
label="Menu1"
menubarPath="linkmenu/linksep2"
style="push"
tooltip="Menu1">
</action>
<action
class="Menu2"
icon="icons/Menu2.gif"
id="Menu2"
label="Menu2"
menubarPath="linkmenu/linksep"
style="push"
tooltip="Menu2">
</action>
<action
class="Menu3"
icon="icons/Menu3.gif"
id="MsCrmAddIn.action1"
label="Menu3"
menubarPath="linkmenu/linksep"
style="push"
tooltip="Menu3">
</action>
</actionSet>
<actionSetPartAssociation targetID="com.ibm.notes.mail.utils.actionSet">
<part id="com.ibm.rcp.csiviews.CSIViewPart" />
</actionSetPartAssociation>
Thanks in advance!
Subject: Assuming you’ve debugged it using Eclipse, or added debug output to see when that event is triggered…
…then I don’t know what else to suggest, but I’m probably not the best person to answer this.