Loading ...
Sorry, an error occurred while loading the content.

50923DataTable to stretch full width of container?

Expand Messages
  • Eric P
    Aug 2, 2009
    • 0 Attachment
      Hi,

      I have a DataTable inside a div. I'm trying to figure out how to have the DataTable stretch to the width of the div.

      I've tried using the width attribute as shown in this example (taken from the "Complex Example of Multiple Features"
      example).

      var myColumnDefs = [
      {key:"areacode",label:"Area Codes",width:100,resizeable:true,sortable:true},
      {key:"state",label:"States",width:250,resizeable:true,sortable:true, sortOptions:{sortFunction:sortStates}},
      {key:"notes",label:"Notes (editable)",editor:"textbox",resizeable:true,sortable:true}
      ];

      But those width values are pixel values; I couldn't get a percentage to work there.

      I also see a setColumnWidth method, but the API says that is for pixel values as well.

      Thanks for reading,
      Eric P.
    • Show all 3 messages in this topic