PDA

View Full Version : Ext JS Direct error in IE 8 "Object doesn't support this propert or method"



naveedanjum
29 Nov 2011, 4:24 AM
Hi,
I am gettitng this error in IE 8. While using EXT JS 4.0.7 in IE 8 on line var f = SampleApp.Direct.... as below.
Following works great in Firefox 8.0



var callbackFun = function( response, e )
{
if( true === e.status )
{
user = Ext.decode( response );

toolbar.down('[name=lblUserName]').setText('Welcome '+user.userName);
toolbar.doLayout();

}
};

var f = SampleApp.Direct.UserInfo.getJSON.bind( callbackFun );
}

mankz
29 Nov 2011, 5:03 AM
Where does 'bind' come from, this is not available in IE. You can use Ext.Function.bind though.

naveedanjum
29 Nov 2011, 8:58 AM
Can you identify what is the problem in above mentioned code. I am using Ext JS Direct. And getJSON is its method. It would be great if you can rewrite the problematic line.

mankz
29 Nov 2011, 9:00 AM
Using Ext 4?


var f = SampleApp.Direct.UserInfo.getJSON.bind( callbackFun );

instead



var f = Ext.Function.bind(SampleApp.Direct.UserInfo.getJSON, callbackFun );