dcsimg
Unable to call the function on onclint event of button using ext-js2.0
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Anonymous
Posted On:   Monday, January 28, 2008 09:48 AM

Hi i am using the below to build my form. Now i am not able to call the myFunc on onclick event of button.Now my function is called at the time of loading the form. I am uding ext js to build form. Please help me in this issue. Thanx Ext.onReady(function(){ var tabs = new Ext.FormPanel({ labelWidth: 80, border:false, width: 400, items: { xtype:'tabpanel', activeTab: 0, defaults:{autoHeight:true, bodyStyle:'padding:10px'}, items:[{ title:xxxx', layout:'form', defaults: {width: 230}, defaultType: 'textfield', items: [{ fieldLabel: "YYYY", xtype:"numberfield", fieldL   More>>

Hi i am using the below to build my form. Now i am not able to call the myFunc on onclick event of button.Now my function is called at the time of loading the form. I am uding ext js to build form.
Please help me in this issue.

Thanx


Ext.onReady(function(){
var tabs = new Ext.FormPanel({
labelWidth: 80,
border:false,
width: 400,

items: {
xtype:'tabpanel',
activeTab: 0,
defaults:{autoHeight:true, bodyStyle:'padding:10px'},
items:[{
title:xxxx',
layout:'form',
defaults: {width: 230},
defaultType: 'textfield',

items: [{
fieldLabel: "YYYY",
xtype:"numberfield",
fieldLabel:"MY Account",
name:"numbervalue",
width:189
} {
xtype:"tbbutton",
fieldLabel:"Submit",
name:"Submit",
onClick:myFunc(),
width:68
}]
},{
title:'History',
layout:'form',
defaults: {width: 230},
defaultType: 'textfield'
},
{
title:'Search',
layout:'form',
defaults: {width: 230},
defaultType: 'textfield'

}]
}
});

tabs.render(document.body);
});

function myFunc(){alert("hi");}

   <<Less

Re: Unable to call the function on onclint event of button using ext-js2.0

Posted By:   Michael_Lowden  
Posted On:   Monday, February 18, 2008 04:40 PM

heya. you might be falling into the same problem as me:

http://www.jguru.com/forums/view.jsp?EID=1356753
About | Sitemap | Contact