EXT Form Designer (guibuilder) simple tutorial

Source: Internet
Author: User

Note: This tutorial is developed in the standard ajax/ext directory environment I recommend. if the environment is different, modify the relevant path on your own.

Download the framework and code of this project

1. Open the project

2. Create demo.html in the root directory:

 

< Html >
< Head >
< Meta HTTP-equiv = "Content-Type" Content = "Text/html; charset = GBK" >
< Title > Extjs GUI designer demo </ Title >
<! -- The extjs base 2.02 -->
< Link REL = "Stylesheet" Type = "Text/CSS" Href = "Framework/ext-2.0.2/resources/CSS/ext-all.css" Temp_href = "Framework/ext-2.0.2/resources/CSS/ext-all.css" />
< Script Type = "Text/JavaScript" SRC = "Framework/ext-2.0.2/adapter/EXT/ext-base.js" Temp_src = "Framework/ext-2.0.2/adapter/EXT/ext-base.js" > </ Script >
< Script Type = "Text/JavaScript" SRC = "Frame/ext-2.0.2/ext-all.js" Temp_src = "Frame/ext-2.0.2/ext-all.js" > </ Script >

<! -- The JSON panel -->
< Script Type = "Text/JavaScript" SRC = "Widget/EXT. UX. jsonpanel. js" Temp_src = "Widget/EXT. UX. jsonpanel. js" > </ Script >
</ Head >

< Body >
< Script >
New Ext. viewport ( {
Items: New Ext. UX. jsonpanel ( {Autoload:'Modules/user. JSON'} ),
Layout: ' Fit '
} ). Show ();
</ Script >
</ Body >
</ Html >

 

Note that user. JSON is generated in guibuilder.Code.

3. Open guibuilder

 

4. Design Interface

1) double-click formpanel or drag formpanel into the main panel.

2) drag textfield to formpanle, change fieldlabel to "username", and add "ID" attribute to "username"

3) insert a button to add a handle event.

4) Click here to edit. The script editing box is displayed. Enter the following information in the field:


Function (){


Alert (Ext. Get ("username"). getvalue ());


}

Enter and click Apply.

5) click Copy JSON or edit JSON to copy the code and save itUser. JSON

6) Open demo.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.