ExtJS notes (i) Ext.onready () usage

Source: Internet
Author: User

definition: after loading the ExtJS library, start loading the function specified in Onready

parameter: Onready (FN, scope, options)

    1. The FN callback function represents the function to be executed
    2. Scope represents the scope of a function
    3. Some of the other features that are performed by the function, such as how many milliseconds to defer execution, and so on, require only the first parameter in most cases.

Case study One: the role of the loading method

a.function A () {     alert ("Every thing is ok!" )}ext.onready (a); B.ext.onready (function () {     alert ("Every thing is ok!" );});

Results Print MsgBox Box:every thing is ok!

Case Study II: Parameter Interpretation

<script type= "Text/javascript" >     var b1={v: "This ID B1"};     var B2={v: "This ID b2"};     Function B () {         alert (this. v);     }     Ext.onready (b,b1,{dealy:"50000000"});     Ext.onready (b,b2,{dealy:"50000000"</script>

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.