如何在asp.net中使用Ajax日历? [英] how can i use ajax calender in asp.net ?

查看:64
本文介绍了如何在asp.net中使用Ajax日历?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好朋友,我只是从ajax开始,但是当我单击文本框上的plz指导我时,我无法显示日历.
我在我的页面上使用此代码.

hello friend i am just start in ajax but i am not able to show calender when i am click on textbox plz guide me
i am using this code on my page.

<asp:TextBox ID="txtDate" runat="server" Width="70">
<asp:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="txtDate" OnClientShown="txtDate" PopupButtonID="txtDate">

推荐答案

/* First Of all Include ToolKit Script Manager */
 <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
 </asp:ToolkitScriptManager>
/* Text Box To take Value From Calendor Extendor
  <asp:TextBox ID="txtDateFrom" runat="server"></asp:TextBox>
/* Image Button on click of which You want to pop Calendor
<asp:ImageButton ID="btnDate2" runat="server" ImageUrl="~/Admin/Images/CalendorIcon.jpg" Width="4%" />
/* Last Your Calendor Extendor
<asp:CalendarExtender ID="CalendarExtender1" TargetControlID="txtDateFrom"  PopupButtonID="btnDate2" runat="server">
</asp:CalendarExtender>



/*有关其他详细信息,请尝试此链接*/

Ajax控件示例和示例 [ ^ ]



/* For Additional Details Try this Link */

Ajax Controls Samples and Examples [^]


在Mohd Wasif给出的答案旁边,为什么不尝试 ^ ]?在ASP.Net中使用非常容易
Beside the answer given by Mohd Wasif, Why don''t you try jQuery UI Date picker[^]? It is quite easy to use in ASP.Net


创建非常简单的
遵循此代码,您轻松获得答案

its very simple to create
follow this code your easily get the answer

/* First Of all Include ToolKit Script Manager */
 <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
 </asp:ToolkitScriptManager>
/* Text Box To take Value From Calendor Extendor
  <asp:TextBox ID="txtDateFrom" runat="server"></asp:TextBox>
/* Image Button on click of which You want to pop Calendor
<asp:ImageButton ID="btnDate2" runat="server" ImageUrl="~/Admin/Images/CalendorIcon.jpg" Width="4%" />
/* Last Your Calendor Extendor
<asp:CalendarExtender ID="CalendarExtender1" TargetControlID="txtDateFrom"  PopupButtonID="btnDate2" runat="server">
</asp:CalendarExtender>


这篇关于如何在asp.net中使用Ajax日历?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆