search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

menu Item

Asked by Balaji KN
12 years ago.
Hi, is it not possible to enable and disable menu item in context menu if possible please reply as early as possible
Comment posted by Dan Letecky
12 years ago.
You could make the menu item text gray by wrapping it inside a span element:

<span style="color:gray">Delete</span>

and set the javascript action to nothing:

void(0);

It could be helpful to create two menus (one with all the items active, one with disabled items) and switch as the context changes (using BeforeEventRender event handler).
Comment posted by Anonymous
12 years ago.

Hi,

please tell me where should i include that <SPAN> in my code

Comment posted by Balaji KN
12 years ago.

if i include <SPAN > inside DayPilot:DayPilotMenu > am getting error

DayPilot:DayPilotMenu ID="contextMenuOnFreeTimeRange" ShowMenuTitle="false" runat="server" MenuBackColor="#FFE0C0" MenuItemColor="#FF8000" MenuTitle=""


DayPilot:MenuItem Text="New" Action="JavaScript" ToolTip="New Event" JavaScript="return onNewEventClick(e)"
DayPilot:DayPilotMenu

Comment posted by Anonymous
12 years ago.
reply as early as possible
Comment posted by Dan Letecky
12 years ago.

It believe encoding the < and > using &lt; and &gt; should work.

You could also add the menu items in the code behind (e.g. in Page_Load method).

This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.