Vertical layout in GridPanel

Page 1 of 2 12 LastLast
  1. #1

    Vertical layout in GridPanel

    How do I display a GridPanel in vertical orientation with 2 columns?
    For example, here is a table with 2 columns and many rows. I need to position GridPanel like this table.

            <td>First row header</td>
            <td>First row data data data data</td>
            <td>Second row header</td>
            <td>Second row data data data data</td>
            <td>Third row header</td>
            <td>Third row data data data data</td>
            <td>Fouth row header</td>
            <td>Fouth row data data data data</td>
    Last edited by AlexMaslakov; Aug 10, 2011 at 12:11 PM.
  2. #2

    Unfortunately, there is no such functionality in GridPanel.

    Not sure but, maybe, you need PropertyGrid.
  3. #3
    it looks good. Perhaps, I'll use it.
  4. #4
    <ext:Store ID="myStore" runat="server" />
    <ext:PropertyGrid ID="PropertyGrid1" runat="server" Width="600" AutoHeight="true" StoreID="myStore"
            <ext:PropertyGridParameter Name="Name1"   />
            <ext:PropertyGridParameter Name="Name2" />
            <ext:PropertyGridParameter Name="Name3" />
            <ext:PropertyGridParameter Name="Name4" />
            <ext:GridView ForceFit="true" ScrollOffset="2" runat="server" />
    protected void Page_Init(object sender, EventArgs e)
                myStore.DataSource = GetData();
            private DataTable GetData()
                DataTable dt = new DataTable();
                dt.Rows.Add("name-data-11", "name-data-22", "name-data-33", "name-data-44");
                return dt;
    How do I map <ext:PropertyGridParameter Name="Name1" /> to "Name1" of myStore (DataTable) ?
  5. #5
    PropertyGrid doesn't use a store
    Just use Source property (set of items (Name/Value pair))
  6. #6
    Source have no setter property. You, probably, mean SetSource() method.
    Thanks, it works as I want.
  7. #7
    You don't need setter for Source, it is ready to use collection, just add to Source own parameters
  8. #8

     Tuple<decimal, decimal, decimal, decimal, decimal, decimal> financeInfo = GetFinance();
                     new PropertyGridParameterCollection
                          new PropertyGridParameter("title1", financeInfo.Item1.ToString()),
                           new PropertyGridParameter("title2", financeInfo.Item2.ToString()),
                           new PropertyGridParameter("title3", financeInfo.Item3.ToString()),
                           new PropertyGridParameter("title4", financeInfo.Item4.ToString()),
                           new PropertyGridParameter("title5", financeInfo.Item5.ToString()),
                           new PropertyGridParameter("title6", financeInfo.Item6.ToString())
    Is there another way to do it?
  9. #9
    Please use:
    PropertyGrid1.Source.Add(new PropertyGridParameter("name", "value"));
  10. #10
    What's the difference between

    PropertyGrid1.Source.Add(new PropertyGridParameter("name", "value"));

     PropertyGrid1.SetSource( new PropertyGridParameterCollection  {  new PropertyGridParameter("name", "value")  });
Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 1
    Last Post: Jul 18, 2011, 8:40 AM
  2. [CLOSED] Two column layout with vertical scroll bar
    By deejayns in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: May 26, 2011, 10:28 PM
  3. [CLOSED] Vertical Button With Text, Or Vertical Tabs
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Apr 21, 2011, 9:43 PM
  4. Replies: 3
    Last Post: Sep 13, 2010, 4:13 PM
  5. Replies: 4
    Last Post: Dec 30, 2009, 1:31 AM

Posting Permissions