Fork me on GitHub
ExtJS专题(十):layout布局的使用(6)
  • form
  • 是一种专门用于管理表单中输入字段的布局 
    .net代码 
    1. Ext.onReady(function() {  
    2.         var win = new Ext.Window({  
    3.             title: "form Layout",  
    4.             height: 150,  
    5.             width: 230,  
    6.             plain: true,  
    7.             bodyStyle: 'padding:15px',  
    8.             items:   
    9.             {  
    10.                 xtype: "form",  
    11.                 labelWidth: 30,  
    12.                 defaultType: "textfield",  
    13.                 frame:true,  
    14.                 items:   
    15.                 [  
    16.                     {  
    17.                         fieldLabel:"姓名",  
    18.                         name:"username",  
    19.                         allowBlank:false  
    20.                     },  
    21.                     {  
    22.                         fieldLabel:"呢称",  
    23.                         name:"nickname"  
    24.                     },  
    25.                     {  
    26.                         fieldLabel: "生日",  
    27.                         xtype:'datefield',  
    28.                         name: "birthday",  
    29.                         width:127  
    30.                     }  
    31.                 ]  
    32.             }  
    33.         });  
    34.         win.show();  
    35.     });  

    posted on 2010-03-11 17:02  HackerVirus  阅读(536)  评论(0编辑  收藏  举报