开发者

maskedextender and calenderextender in asp.net

开发者 https://www.devze.com 2023-03-19 17:04 出处:网络
I am new person in asp.net. I have one text box and one calender image button in my asp.net application. I use the masked extender to display date in the textbox like yyyy-mm--dd. Also i use the calen

I am new person in asp.net. I have one text box and one calender image button in my asp.net application. I use the masked extender to display date in the textbox like yyyy-mm--dd. Also i use the calender extender for the purpose of clicking image button it will show the date in the textbox. I use the following code.

                                    &nbsp;<asp:ImageButton ID="imgdatefrom" runat="server" 
                                        ImageU开发者_C百科rl="~/images/calendar.jpeg" Height="19px" Width="20px"  />
                                    &nbsp;&nbsp;<asp:Label ID="lblTo"  runat="server" Text="End Date" 
                                        ForeColor="Black" Font-Size="Small"></asp:Label>
                                    <asp:Label ID="enddateval" runat="server" ForeColor="Red" Text="*"></asp:Label>
                                    &nbsp;<asp:CalendarExtender ID="txtDateFrom_CalendarExtender" runat="server" TargetControlID="txtDateFrom" Format="yyyy-MM-dd" PopupButtonID="imgdatefrom"
                                                        TodaysDateFormat="yyyy d, MMMM">
                                        </asp:CalendarExtender>

While I executing that code and selecting date by clicking image button the selected date will not displayed in the textbox. Can anyone know how to solve the problem. Thank you


Instead of MaskedExtender you just use standard TextBox Control. It will work.

0

精彩评论

暂无评论...
验证码 换一张
取 消