Click here to Skip to main content
16,019,273 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
i have create a web page with one textbox.
When i click on textbox calender will display.
And for that textbox i am not add calender extender from add extender option
-->i require yo add that extender through code ,

How it possible
Posted

1 solution

Go to the Page_Load event of webpage. Create an object of CalanderExtender and set the TargetControlID of that extender object to your textbox. Try this:
C#
CalanderExtender  ce= new CalanderExtender();
ce. TargetControlID = TextBox1.ClientID;



--Amit
 
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