Click here to Skip to main content
15,897,371 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hello, i have trying a lot of ways to solve this solution but my ajax calender does not work? When i create a new website, the ajax calender can work and appear in the website BUT in my website does not appear. It is because of weconfig problem or css problem???i does not have any idea to settle it down
Posted
Comments
Monjurul Habib 3-Apr-11 4:02am    
Share your code to understand your problem.
nazila24 3-Apr-11 4:09am    
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default3.aspx.vb" Inherits="Default3" %>

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>

<asp:TextBox ID="TextBox1" runat="server">
<asp:CalendarExtender ID="TextBox1_CalendarExtender" runat="server"
Enabled="True" TargetControlID="TextBox1">

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


</div>
</form>
</body>
</html>


my tax prefix = asp not ccl...when i create another website, the tax prefix = ccl..i dont know why this problem occur

1 solution

Put this at the top of all controls, just after form tag starts:
XML
<asp:ScriptManager ID="ScriptManager1" runat="server">

And also, put your CalendarExtender inside UpdatePanel.


About tag prefix: There is no issue in it. It's just an alias defined at the top of the page itself. Here:
XML
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>

Whatever alias you define here, it works accordingly.
 
Share this answer
 
v2
Comments
nazila24 3-Apr-11 6:02am    
Thank you for your information but when i put calender extender inside UpdatePanel error 'Type 'System.Web.UI.UpdatePanel' does not have a public property named 'CalendarExtender''' has occur.
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default3.aspx.vb" Inherits="Default3" %>

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>

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

<asp:TextBox ID="TextBox1" runat="server">
<asp:UpdatePanel ID="UpdatePanel1" runat="server">

<asp:CalendarExtender ID="TextBox1_CalendarExtender" runat="server"
Enabled="True" TargetControlID="TextBox1">


</div>
</form>
</body>
</html>

it is wrong?
Sandeep Mewara 3-Apr-11 6:26am    
Yes. Read on how to use Update panel.

You need ContentTemplate in Update Panel and then put the extender in it.
Further, you missed closing tags of update panel.

Here:
http://msdn.microsoft.com/en-us/library/system.web.ui.updatepanel.aspx
http://msdn.microsoft.com/en-us/library/bb386454.aspx

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900