1. #1
    Sencha User
    Join Date
    Jun 2011
    Location
    Bangalore, India
    Posts
    175
    Answers
    4
    Vote Rating
    2
    renganathan is on a distinguished road

      0  

    Default Unanswered: Grid column width as autofit

    Unanswered: Grid column width as autofit


    Hi all,

    i want to do auto fit for all column based on the content without using
    Code:
    Forcefit: true;
    Guys please help me to fix this problem

    Here is my code
    Code:
    
    // view port
       var vport = new Ext.Viewport(
    {
           layout : 'border',
           items  : 
    [
    { 
    height : 70,
    // autoWidth   : true,
                   region : 'north',
    border : true,
    items :
    [
    { 
    xtype : 'box',
    width : '18%',
    autoEl : {tag: 'img', src:'./ciscologo.png'}
    },
    { 
    xtype : 'panel',
    // autoWidth : true,
    items   : 
    [
    { 
    xtype : 'button', 
    text : 'Button 1'
    },
    { 
    xtype : 'button', 
    text : 'Button 2'
    }
    ]
    }
    ]
    }, 
               {
                   width   : '250',
                   region : 'west',
    layout   : 'fit',
    collapsible : true,
    title : 'Navigation Panel',
    items : [navPanel]
               },
               {
    autoWidth   : true,
                   region : 'center',
    layout   : 'fit',
       items    : [grid]
               }
           ]
       });
    
    //  Grid code
    
    var grid = new Ext.grid.GridPanel(
    {
    id : 'gridPan',
    autoScroll : true,
    store : dstore,
    title   : 'Grid Panel',
    columns :
    [
    {id:'ipaddr', header: "ipaddr", sortable: true, dataIndex: 'ipaddr'},
    {id: 'devicetype', header: "devicetype", dataIndex: 'devicetype'},
    {id:'status', header: "status", dataIndex: 'status'},
    {id: 'description', header: "description", dataIndex: 'description'}
    ],
     columnLines : true,
    loadMask : true,
    stripeRows: true,
     autoExpandColumn: 'description'
      });

    when i am using forcefit is true, i am facing some problem like (Reloading problem,Horizontal scroll not coming and etc)

    Thanks in advance,

    Renganathan
    Thanks,

    RENGANATHAN M G

  2. #2
    Sencha Premium Member skirtle's Avatar
    Join Date
    Oct 2010
    Location
    UK
    Posts
    3,580
    Answers
    540
    Vote Rating
    316
    skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future skirtle has a brilliant future

      0  

    Default


    Please indent your code properly before posting it. There's not much point using CODE tags if you don't include decent indentation.

    Your question is quite confusing. Your grid has 4 columns. Could you describe exactly how you'd like each of them to be sized?

    I also see a lot of ExtJS 3 in your code. Are you are using ExtJS 3 or 4?

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi