Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
113
PopupMenu with ClientId still not valid
posted

I'm trying to get a popup menu to appear on an onclick client side event, when using a masterpage.  Am using Vol 3 CLR3.5, have looked at the other posts indicating name versus ClientId within masterpages.  This still is not working for me, even though the name is resolving properly.  Here is my code:

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

<script type="text/javascript">

function PopupMenu()

{

if(event.button == 0 || event.button == 1)

{

var x = '<%= UltraWebMenu1.ClientID%>';

alert(x);

igmenu_showMenu(x, event);

event.returnValue =
false;event.cancelBubble=true;

}

}

</script>

<ignav:ultrawebmenu id="UltraWebMenu1" runat="server" javascriptfilename="" javascriptfilenamecommon=""

targetframe="" targeturl="" webmenutarget="PopupMenu">

<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">

</ignav:Item>

</Items>

<DisabledStyle Font-Names="MS Sans Serif" Font-Size="8pt" ForeColor="Gray">

</DisabledStyle>

<Levels>

<ignav:Level Index="0" />

</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>

 

<a onclick="PopupMenu()">test</a>

 

</asp:Content>

 I always get the proper name of ctl00_ContentPlaceHolder1_UltraWebMenu1, but then Popup menu name is not valid.  What am I doing wrong?  THanks.

Parents Reply Children