I Have one Content page of Master Page
Source File for content page
---------------------------------------------------------------------------------------------------------------------------------
<%
@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" Title="Untitled Page" %>
<
asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<
div>
<asp:TextBox ID="TextBox1" runat="server" Style="z-index: 100; left: 71px; position: absolute;
top: 152px"></
asp:TextBox><IMG src="smcal.gif" alt="Select Date" id="Img1" style="z-index: 100; left: 243px; position: absolute; top: 154px" />
<SCRIPT>
Calendar.setup({inputField :
"TextBox1", ifFormat : "%d-%b-%Y", button : "Img1"});
</
SCRIPT>
</div>
</
asp:Content>
----------------------------------------------------------------------------------------------------------------------
Master Page
<%
@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>
<!
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>
<LINK href="style.css" type="text/css" rel="stylesheet">
<
LINK href="styleset.css" type="text/css" rel="stylesheet">
<
LINK href="calendar-win2k-1.css" type="text/css" rel="STYLESHEET">
<
script src="calendar.js" type="text/javascript"></script>
<
script src="calendar-en.js" type="text/javascript"></script>
<
script src="calendar-setup.js" type="text/javascript"></script>
</
head>
<
body>
<form id="form1" runat="server">
<div>
<asp:contentplaceholder id="ContentPlaceHolder1" runat="server">
</asp:contentplaceholder>
</div>
</form>
</
body>
</
html>
But when i Clicked on the image of Calender it should display Calender but It gives error Null value or null reference .
This is only with master page but when i done same thing in simple default.aspx page it is working fine.
is there any way to write down below script different for Master Page
<SCRIPT>
Calendar.setup({inputField :
"TextBox1", ifFormat : "%d-%b-%Y", button : "Img1"});
</
SCRIPT>
Please reply as soon as possible