Columntree width problem in ExtJs

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mrbadboy
    New Member
    • Jul 2007
    • 21

    Columntree width problem in ExtJs

    Hi,

    i tried to set columntree width using widht and forcefit property (in ExtJS). but im not getting the proper solutions. If i change the screen resolution its not fit with full width. i've attached below my code.
    [CODE=javascript]
    createTree = function (){
    tree = new Ext.tree.Column Tree({
    el:'adminGridDi v',
    id:'producttree ',
    width:700,
    rootVisible:fal se,
    expandable:fals e,
    loadMask: true,
    layout:'fit',
    viewConfig: {
    forceFit:true
    },
    stripeRows: true,
    singleClickExpa nd:true,
    tbar: new Ext.Toolbar({
    autoHeight:true ,
    autoWidth:true,
    style:'backgrou nd:#d0def0'
    }),
    columns:[
    {
    header:'Group Name',
    width:120,
    id:'name',
    dataIndex:'name '
    },{
    header: "Status",
    dataIndex: 'status',
    id:'status',
    width: 90
    })
    },{
    header:'Remarks ',
    width:170,
    id:'remarks',
    dataIndex:'rema rks'
    }],

    loader: new Ext.tree.TreeLo ader({
    layout:'fit',
    width:980,
    preloadChildren :true,
    uiProviders:{
    'col': Ext.tree.Column NodeUI
    }
    })

    });
    }[/CODE]


    reply me if you have any idea...

    Thanks
    Last edited by acoder; Apr 21 '08, 10:45 AM. Reason: Added code tags
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    Originally posted by mrbadboy
    i tried to set columntree width using widht and forcefit property (in ExtJS). but im not getting the proper solutions. If i change the screen resolution its not fit with full width.
    If you're setting the width, then the width will be 700, not the full screen, would it?

    Please use [code] tags when posting code. Thanks!

    Comment

    • mrbadboy
      New Member
      • Jul 2007
      • 21

      #3
      Originally posted by acoder
      If you're setting the width, then the width will be 700, not the full screen, would it?

      Please use [code] tags when posting code. Thanks!


      Thanks for your reply... actually somebody has tried with
      layout:'fit',
      viewConfig: {
      forceFit:true
      }

      URL :
      http://extjs.com/forum/showthread.php? t=31880&highlig ht=columntree+f orcefit

      to fix it... even total width of the columntree is not working...


      Thanks.

      Comment

      Working...