Asp.net Ajax calendar control usage

Source: Internet
Author: User

The date Selection control is useful in many places, and there are many implementation methods. I once wrote a lame JS date control, so I pasted the code because it was too bad. Today we will introduce the Ajax calendar control provided by Microsoft. This control uses Ajax effects and sets events and effects through front-end JS and style. Rich functions and styles are essential for website design and MIS development.

By convention, it is now time to paste the Code:

<Asp: textbox runat = "server" id = "txtcalendar" width = "150"/>
<Ajaxtoolkit: calendarextender runat = "server" targetcontrolid = "txtcalendar" cssclass = "mycalendar"
Format = "yyyy-mm-dd"/>

Because the style is set, we can paste the code here, just write a simple style:

. Mycalendar. Ajax _ calendar_container
{
Border: 1px solid #646464;
Background-color: maroon;
Color: red;
}

When we run this way, you will find that the English language is poor, and we do not have any Chinese. What makes us feel so embarrassed! What should we do? Of course, there are solutions that can be easily implemented. If you do not want to sell off the customs, you only need to set enablescriptglobalization and enablescriptlocalization to true.

Let's talk about the attributes. targetcontrolid is not mentioned. format is the display style, which is the same as the date format in C. Popupbuttonid is the ID of the pop-up button control.

There are many styles:

. Ajax _ calendar_container

. Ajax _ calendar_header

. Ajax _ calendar_prev

. Ajax _ calendar_title

............ A lot of, you can see this URL: http://www.asp.net/ajax/ajaxcontroltoolkit/Samples/Calendar/Calendar.aspx

The usage has been introduced. Continue to study!

The date Selection control is useful in many places, and there are many implementation methods. I once wrote a lame JS date control, so I pasted the code because it was too bad. Today we will introduce the Ajax calendar control provided by Microsoft. This control uses Ajax effects and sets events and effects through front-end JS and style. Rich functions and styles are essential for website design and MIS development.

By convention, it is now time to paste the Code:

<Asp: textbox runat = "server" id = "txtcalendar" width = "150"/>
<Ajaxtoolkit: calendarextender runat = "server" targetcontrolid = "txtcalendar" cssclass = "mycalendar"
Format = "yyyy-mm-dd"/>

Because the style is set, we can paste the code here, just write a simple style:

. Mycalendar. Ajax _ calendar_container
{
Border: 1px solid #646464;
Background-color: maroon;
Color: red;
}

When we run this way, you will find that the English language is poor, and we do not have any Chinese. What makes us feel so embarrassed! What should we do? Of course, there are solutions that can be easily implemented. If you do not want to sell off the customs, you only need to set enablescriptglobalization and enablescriptlocalization to true.

Let's talk about the attributes. targetcontrolid is not mentioned. format is the display style, which is the same as the date format in C. Popupbuttonid is the ID of the pop-up button control.

There are many styles:

. Ajax _ calendar_container

. Ajax _ calendar_header

. Ajax _ calendar_prev

. Ajax _ calendar_title

............ A lot of, you can see this URL: http://www.asp.net/ajax/ajaxcontroltoolkit/Samples/Calendar/Calendar.aspx

The usage has been introduced. Continue to study!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.