Hii,
You can solve this problem with the help of JavaScript:-
Step1:- Create a TextBox:-
<input type="text" runat="server" önclick="show()" />
or
<asp:TextBox ID="txtShowMenu" onclick="show()" runat="server"></asp:TextBox>
Here you find a Onclick Event:- show() :- to call the js function
Step 2:- add a Menu:- and set iys disply property none:- display:none
<asp:Menu ID="Menu1" runat="server" Width="152px" style="display:none;">
<Items>
<asp:MenuItem Text="Menu1" Value="New Item">
<asp:MenuItem Text="Submenu1" Value="Submenu1"></asp:MenuItem>
</asp:MenuItem>
</Items>
</asp:Menu>
Step 3:
Write the js code
<script language="javascript" type="text/javascript" >
function show()
{
document.getElementById("Menu1").style.display='';
}
</script>
The Whole Sample:->
<head runat="server">
<title>Untitled Page</title>
<script language="javascript" type="text/javascript" >
function show()
{
document.getElementById("Menu1").style.display='';
}
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<%----%>
<asp:TextBox ID="txtShowMenu" onclick="show()" runat="server"></asp:TextBox> <br />
<asp:Menu ID="Menu1" runat="server" Width="152px" style="display:none;">
<Items>
<asp:MenuItem Text="Menu1" Value="New Item">
<asp:MenuItem Text="Submenu1" Value="Submenu1"></asp:MenuItem>
</asp:MenuItem>
</Items>
</asp:Menu>
</div>
</form>
</body>