PDA

View Full Version : What could be the possible error in the below code



venkateshwar
1 Feb 2013, 12:28 AM
I am very new to extjs and going through the documentation. http://docs.sencha.com/ext-js/4-0/#!/guide/layouts_and_containers. In the section 'container', there is the following code which is not doing anything on my page(blank page, no panels)


Ext.create (http://docs.sencha.com/ext-js/4-0/#!/api/Ext-method-create)('Ext.panel.Panel (http://docs.sencha.com/ext-js/4-0/#!/api/Ext.panel.Panel)', { renderTo: Ext.getBody (http://docs.sencha.com/ext-js/4-0/#!/api/Ext-method-getBody)(), width: 400, height: 300, title: 'Container Panel', items: [ { xtype: 'panel', title: 'Child Panel 1', height: 100, width: '75%' }, { xtype: 'panel', title: 'Child Panel 2', height: 100, width: '75%' } ]});
Please check this and help me..

Thanks.

sriram139
1 Feb 2013, 12:39 PM
There seems to be no problem with the code you pasted.
If you want to verify, go to below link:
http://try.sencha.com/extjs/4.1.1/docs/Ext.panel.Panel.2/viewer.html

Paste your code within Ext.onReady(function () {}); and see.
There might be problem with your html code or app code around this. check that.

Thanks,
Sriram

venkateshwar
1 Feb 2013, 7:19 PM
Thank you for reply. I got the solution here http://stackoverflow.com/q/14641808/1577396.

These sencha forums are good but not upto mark in my opinion. So, I created a group on SO where we can have discussions regarding sencha. Please have a look at this link http://chat.stackoverflow.com/rooms/23760/sencha (require sign up).

I even created on Jabbr where many developers are available https://jabbr.net/#/rooms/Sencha

I meant no disrespect.. I am just trying to expand sencha forums.

Please give reply as feedback here even if you don't like my approach. :)

Thank you.