Vinzcent
Vinzcent

Reputation: 1448

Ajax Calendar Extender doesn't work

I know this is a silly question, bu I just can't get the ASP.Net Calendar Extender work. I am looking at this problem for hours now. Can someone please help me.

I've downloaded the code from the Asp.net Ajax website and I've added the dll to my toolbox.

This is the code of my page

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>

<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<asp:CalendarExtender TargetControlID="TextBox1" runat="server"></asp:CalendarExtender>

When I click the TextBox, it behaves like a normal TextBox. It doesn't show the calendar.

Is there something I forget, or is there something I am doing wrong?

Upvotes: 1

Views: 4027

Answers (2)

Garth
Garth

Reputation: 1446

Replace ScriptManager With ToolkitScriptManager

Upvotes: 3

KBoek
KBoek

Reputation: 5976

You forgot to set the PopupButtonID property of the CalendarExtender. If you want the calendar to appear when you click on the TextBox, use PopupButtonID="TextBox1"

Upvotes: 1

Related Questions