Click here to Skip to main content
15,892,005 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am creating register page..in register page i want to mention date of birth using calender.when user fill the dob(date of birth option) to select the day,month and year show the calender to select....please help me

thank u
code project
Posted
Updated 30-Aug-12 19:39pm
v2
Comments
Sanjay K. Gupta 31-Aug-12 1:23am    
Data of Birth?

Hello @singh dev,

hope below solution will help you,


XML
<asp:TextBox ID="txtBorrowerBirthDate" runat="server" SkinID="text" Width="90px"
                                                                                    ></asp:TextBox>
                                                                                <asp:ImageButton ID="imgBorrowerBirthDate" runat="server" ImageUrl="~/Images/pickdt.gif">
                                                                                </asp:ImageButton>
                                                                                <cc1:CalendarExtender ID="CalendarExtender2" runat="server" Format="MM/dd/yyyy" PopupButtonID="imgBorrowerBirthDate"
                                                                                    TargetControlID="txtBorrowerBirthDate" Enabled="True">
                                                                                </cc1:CalendarExtender>
 
Share this answer
 
Comments
Devendra 1988 31-Aug-12 4:43am    
hello madhuri some content error or i can't understand if you explain about
madhuri@mumbai 31-Aug-12 6:09am    
Sorry,
I have placed my code here,
instead of cc1 you just use <AjaxControlToolkit:CalendarExtender ID="CalendarExtender2" runat="server" Format="MM/dd/yyyy" ....>


becoz its a ajax control..
Create Selectedchanged event of calender

ex.
C#
protected void Calendar1_SelectionChanged(object sender, System.EventArgs e)
{
    Textbox1.Text=Calender1.selecteddate.Tostring();
}
 
Share this answer
 
v2
 
Share this answer
 
You need a popup calendar.

There are lots of example you will find, if you simply goiogle it.

Here are few links which will guide you to create popup calendar in ASP.NET,

Customizing the ASP.NET Calendar Control[^]

http://www.devx.com/tips/Tip/41898[^]

How to use ASP.NET AJAX Calender Extender[^]


Hope this helps.
cheers
 
Share this answer
 

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



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