<asp:TextBox Text="demo" ID="TextBox6" runat="server" /> <asp:ImageButton ID="imgPopup" ImageUrl="images/calendar_icon.png" ImageAlign="Bottom" OnClick="show_date"
runat="server" /><asp:Calendar id="Calendar1" Visible="false" onselectionchanged="Date_Selected" runat="server" />
--------------------
Sub Date_Selected(ByVal sender As Object, ByVal e As EventArgs)
TextBox6.Text = Calendar1.SelectedDate.ToShortDateString
Calendar1.Visible = "false"
End Sub
Sub show_date()
If Calendar1.Visible = "true" Then
Calendar1.Visible = "false"
Else
Calendar1.Visible = "true"
TextBox6.Text = ""
End If
End Sub