How can I include an Asp.NET page in many other Asp.Net pages so that I don’t need to rewrite the code?
One of the approaches is to write and use a UserControl. You can define the user interface, handle events and expose properties in a UserControl, and then mark a reference and reuse these Controls in any page of your Web application. Here is some Sample code
Is there anything similar to web templates in ASP that I can use in ASP.Net?
In ASP.NET, you would typically use a User Control to create reusable controls.
How can I set the Selection of the Calendar Control to date or week or month
Set the SelectionMode =DayWeekMonth You can set it to any of the following: Day DayWeek DayWeekMonth None
How can I change the month and Weekdays to Japanese characters for a Calendar Control
Set the Culture= ‘ja-JP’ for the Page. ASP.NET pages support Culture and UICulture attributes to support independent localized pages. Controls on pages can pick the culture of the page and can render culture-dependent content.
How to display multiple dates selected in Calendar Control
Set the SelectionMode property of Calendar Control to DayWeek/ DayWeekMonth. Code for the OnSelectionChanged as follows: VB.NET Dim day As DateTime Dim strval As String For Each day In Calendar1.SelectedDates strval += (day.Date.ToShortDateString() & ‘<br>’) Next Response.Write(strval) C# string strval=” ; foreach (DateTime day in Calendar1.SelectedDates) { strval += (day.Date.ToShortDateString() + ‘<br>’); } Response.Write(strval); }