[CLOSED] GridPanel columns autosize

  1. #1

    [CLOSED] GridPanel columns autosize

    Hello,

    I want to have the columns of a gridpanel autosize according to the data inside.

    I found a solution on http://forums.ext.net/showthread.php...e-every-column but it's not working in the new version because there is no getColumnModel method on the grid.

    Is there another solution? Or how can this solution be adapted to the new version?

    Thanks
    Last edited by Daniil; Oct 10, 2014 at 3:36 PM. Reason: [CLOSED]
  2. #2
    Hi @lasting,

    I have not seen a solution for Ext.NET v2. It should be very similar. Just it needs to update the scripts.

    Please review this document searching for "getColumnModel".
    https://examples2.ext.net/#/Getting_...AKING_CHANGES/

    It might contain some tips what to replace with.
  3. #3
    Yes, it shows for
    GridPanel1.getColumnModel().columns
    that it can be accessed using
    var headerCt = App.GridPanel1.headerCt;
    columns = headerCt.getGridColumns();
    But there are some other issues. For example
    view.getCell(rowIdx, colIdx)
    , there is no getCell method on the view and I did not find any records of this method on Breaking changes.
  4. #4
    You can also review the ExtJS API docs.
    http://docs.sencha.com/extjs/4.2.1/#!/api

    There is still the getCell method.
    http://docs.sencha.com/extjs/4.2.1/#...method-getCell

    It is private now for some reason (I don't know why) and the parameters have been changed. Though, I would try to use it.

Similar Threads

  1. Replies: 1
    Last Post: Jul 03, 2014, 8:32 AM
  2. [CLOSED] Dynamic GridPanel - AutoSize every column?
    By vaultview in forum 1.x Legacy Premium Help
    Replies: 27
    Last Post: Mar 12, 2013, 1:37 PM
  3. [CLOSED] Tooltip autosize
    By FpNetWorth in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: Jan 30, 2013, 11:11 PM
  4. Replies: 0
    Last Post: Aug 23, 2012, 11:55 PM
  5. Autosize GridPanel inside UserControl
    By petlun in forum 1.x Help
    Replies: 3
    Last Post: Dec 19, 2008, 6:16 PM

Tags for this Thread

Posting Permissions