Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
440
Size of cell
posted

Hi,

How can I get or calculate actual size of cell in InitializeLayout ?

Thanks.

 

 

Parents
  • 71886
    Offline posted

    Hello,

    You could do this through the following code:

            private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)

            {

                ultraGrid1.Rows[0].Cells[0].Width;

                ultraGrid1.Rows[0].Cells[0].Height;

            }

    The size could be changed by changing the column's width and row's height:

            private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)

            {

                e.Layout.Bands[0].Columns[0].Width = 33;

                ultraGrid1.Rows[0].Height = 33;

            }

    You could also use the 'InitializeRow' event when you are referring to a row.

    Please do not hesitate to contact me if you need any additional assistance.

Reply Children