C # pop-up window and jump to the page

Source: Internet
Author: User

Attributes. Add ("javascript event", "javascript statement ");

For example:

This. textbox1.attributes. Add ("onblue", "window. label1.style. backgroundcolor = '#000000 ';");

This. textbox1.attributes. Add ("onblur", "This. style. Display = 'none '");

Javascript events:

Onclick: Click an event.

Ondblclick double-click event

The button on the onmousedown mouse is pressed

Events triggered when the onmouseup mouse is pressed and released

Onmouseover event triggered when the mouse moves over an object range

Event triggered when the onmousemove mouse moves

Onmouseout event triggered when the mouse leaves an object range

Onkeypress events triggered when a key on the keyboard is pressed and released. [Note: the page must contain focused objects]

Onkeydown events triggered when a key on the keyboard is pressed [NOTE: The page must contain focused objects]

Onkeyup events triggered when a button on the keyboard is pressed and opened [NOTE: The page must contain focused objects]

 

Attributes. after adding add, a certain speed will be affected. attributes and attributes. after cssstyle is automatically saved to viewstate, the load viewstate burden increases at the time of PostBack, in addition to the sudden increase in viewstate volume.

Add the following event in the following format:
Protected override void render (htmltextwriter output)
{
This. attributes ["ABC"] = "123 ";
This. Attributes. cssstyle ["ABC-style"] = "123-style ";
Output. Write (text );
}
Attributes and attributes. cssstyle will no longer be saved to viewstate.

 

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.