- Online Barcode Generator
- How To
- Buy Now
As you can see in other tutorial pages, we can add and implement DatePicker, DateTimePicker, and TimePicker controls of Kettic Web Calendar UI for ASP.NET AJAX library to embed many date pickers, time pickers or datetime pickers on a page. However, too many such pickers on a single page can render too much HTML and effect performance.
In order to solve this problem, we can use a single Calendar or TimeView control to share DatePicker, DateTimePicker, and TimePicker components. Subsequently, the rendered web page only needs to display single client-side object for all the controls' popups. And we still can define the shared popup object at design time or at runtime with simple to integrate ASP.NET example codes.
How to Add the Shared Calendar/TimeView at Design Time
Following step by step instructions are used to define a shared popup at design time.
Check out following ASPX.NET demo codes.
And please note that: the rendered Calendar or TimeView control does not contain any original properties (such as MaxDate and MinDate) from the components that use it.
Adding the Shared Calendar/TimeView at Runtime Time
Following detailed guides are to define a shared popup at run time within ASP.NET project.
At the very beginning, we need to drag and drop TimePicker,DatePicker, and DateTimePicker controls to the web page, and do not set the Calendar or TimeView properties of the Calendar and TimeView.
And then add a PlaceHolder to the page for controling the dynamically created popups. Please refer to following demo ASP.NET codes to see how to add a PlaceHolder to the page.
At last, add the codes for share Calendar/TimeView to the C# codes instance.
See More Related Kettic Web UI Controls
ASP.NET AJAX UI Controls