How to implement jquery calender text box with in repeater

Posted by Raghuldrag under ASP.NET on 8/21/2014 | Points: 10 | Views : 428 | Status : [Member] | Replies : 1
Hi Friends,

i m creating one application the concept is insert jquery date in repeater control in c# so i made code

in asp.net:
-------------

<link rel="stylesheet" href="//code.jquery.com/ui/1.11.1/themes/smoothness/jquery-ui.css"/>
<script src="//code.jquery.com/jquery-1.10.2.js"></script>
<script src="//code.jquery.com/ui/1.11.1/jquery-ui.js"></script>
<link rel="stylesheet" href="/resources/demos/style.css"/>
<script>
$(function () {
$("#<%= Date.ClientID %>").datepicker();
});
</script>
</head>
<body>
<form id="form1" runat="server">


<asp:Repeater ID="Rep" runat ="server" >

<HeaderTemplate>
<table cellpadding="1" cellspacing="1" width="100%" style="font-family:Verdana;border:1px solid #C0C0C0;background-color:#D8D8D8">
<tr style="background-color:#FF781E">
<th>
ID
</th>
<th>
Customer
</th>
<th>
Date
</th>
</tr>



</HeaderTemplate>

<ItemTemplate>
<tr style="background-color:White">
<td>
<asp:TextBox ID="id" runat="Server" Text='<%#Eval("id")%>'></asp:TextBox>

</td>
<td>
<asp:TextBox ID="Cus_name" runat="Server" Text='<%#Eval("Cus_name")%>'></asp:TextBox>
</td>
<td>
<asp:TextBox ID="Date" runat="server"></asp:TextBox>
</td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
<br />

<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Insert" />



Error : The name 'Date' does not exist in the current context




Responses

Posted by: Naveenhcl on: 9/3/2014 [Member] Starter | Points: 25

Up
0
Down
Hi,

Try like below,
$("#<%=GridView1.ClientID%> input[id*='TextBox1']").datepicker();


Raghuldrag, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response