Call the clientscript. registerclientscriptblock method in the user space.

Source: Internet
Author: User

 

The namespace of clientscript is system. Web. UI. Page. Only page after instantiation can be used with clientscript. The user-defined space does not inherit from the page, so the clientscript class cannot be used directly. To use this class, you need to find the method to call the Page Object. Specific practice: after this. Parent. Page finds this object, you can freely call the classes and methods in the namespace of system. Web. UI. Page, just like on a common page. Reference: Why can't the user control page be found. clientscript. registerclientscriptblock reason http://blog.csdn.net/sendling/archive/2008/07/11/2637287.aspxthis article comes from the tornnet http://www.ljf.cn /;

 

The namespace of clientscript is system. Web. UI. Page. Only page after instantiation can be used with clientscript.

The user-defined space does not inherit from the page, so the clientscript class cannot be used directly.

To use this class, you need to find the method to call the Page Object.

 

Specific Practices:

 

 this.Parent.Page

 

After finding this object, you can freely call the classes and methods in the namespace of system. Web. UI. Page, just like on a common page.

 

Refer:

Why the user control page cannot find. clientscript. registerclientscriptblock cause http://blog.csdn.net/sendling/archive/2008/07/11/2637287.aspx

 

This article comes from tornado Information Network http://www.ljf.cn /;

Address: http://www.ljf.cn/2009/9/Item231232.html

 

 

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.