A nice to have, but the customer would be very appreciative if he/she knows that they cannot click on a menu item because of a security model.
I am using a WebMenu.
Each item has an Enabled property. If I set the Enabled property of a menu item to false than the highlight does not appear and the customer cannot click on it. Very good so far.
However, it would be nice to visually inform the customer (maybe through 'greying out' the menu item text) that - Yes we do know that you cannot select that menu item. Right now our customer base will probably think it is a bug.
Hello Roger,
I believe in this situation you can take advantage of our DisabledStyle style class - you can sent font face, size and color (for example to gray) for all disabled items on the menu. In the example below, I have set gray to be the default style for disabled items:
<ignav:UltraWebMenu ID="UltraWebMenu1" runat="server" JavaScriptFilename="" JavaScriptFileNameCommon="" LeafItemImageUrl="" ParentItemImageUrl="" StyleSetName=""> <IslandStyle BackColor="LightGray" BorderStyle="Outset" BorderWidth="1px" Cursor="Default"> </IslandStyle> <HoverItemStyle BackColor="DarkBlue" Cursor="Default" ForeColor="White"> </HoverItemStyle> <Images> <SubMenuImage Url="ig_menuTri.gif" /> </Images> <ItemStyle Cursor="Default" /> <Items> <ignav:Item Text="Top Item"> <Items> <ignav:Item Text="Sub Menu Item"> </ignav:Item> <ignav:Item Enabled="False" Text="Sub Menu Item"> <Styles ForeColor="#666633"> </Styles> </ignav:Item> <ignav:Item Text="Sub Menu Item"> </ignav:Item> </Items> </ignav:Item> <ignav:Item Text="Top Item"> <Items> <ignav:Item Text="Sub Menu Item"> </ignav:Item> <ignav:Item Text="Sub Menu Item"> </ignav:Item> <ignav:Item Text="Sub Menu Item"> </ignav:Item> </Items> </ignav:Item> </Items> <DisabledStyle Font-Names="MS Sans Serif" Font-Size="8pt" ForeColor="Gray"> </DisabledStyle> <Levels> <ignav:Level Index="0" /> <ignav:Level Index="1" /> </Levels> <SeparatorStyle BackgroundImage="ig_menuSep.gif" CssClass="SeparatorClass" CustomRules="background-repeat:repeat-x; " /> <ExpandEffects ShadowColor="LightGray"></ExpandEffects> <MenuClientSideEvents InitializeMenu="" ItemChecked="" ItemClick="" SubMenuDisplay="" ItemHover=""></MenuClientSideEvents> </ignav:UltraWebMenu>
Hope this helps.
Rumen,
I tracked on that earlier. For some reason the control ignores the 'DisabledStyle' settings. I am currently using 2007v3. The way the control seems to be functioning is that the highlight changes as my cursor hovers over the item. When my cursor hovers over a menu item that has it's enabled property set to False that menu item is not 'Highlighted' and cannot be selected. That is a visual cue, but I think it may be confusing to new customers.
Maybe Preset I chose is interfering with it. It seems to have made two styles, but never seems to have used them. This menu is set to be a Popup menu.