EXTJS - HOW TO SET BORDER FOR THE CONTAINER.

Pooja Malohtra

Total Post:47

Points:331
Posted by  Pooja Malohtra
 997  View(s)
Ratings:
Rate this:
I have created a container, now I want to create border for our container.
My container code is below:
MyContainer = Ext.extend(Ext.Container, {
    height: 50,
    width: 300,
    id: 'container1',
    initComponent: function() {
        MyContainer.superclass.initComponent.call(this);
    }
});
Please help me.!
  1. Tarun Kumar

    Post:214

    Points:1642
    Re: Extjs - How to set border for the Container.

    You can set the border like this:

     MyContainer = Ext.extend(Ext.Container, {
        height: 50,
        width: 300,
        id: 'container1',
        border: 1,
        style: {
           borderColor: 'blue',
           borderStyle: 'solid'
        },
        initComponent: function() {
            // do your stuff here
        }
    });

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!