This is a migrated thread and some comments may be shown as answers.

Left align text in Column

1 Answer 276 Views
VirtualGrid
This is a migrated thread and some comments may be shown as answers.
Rohit
Top achievements
Rank 1
Rohit asked on 25 Jan 2018, 06:25 AM

Hi 

How can I left align the text in the virtualGrid (with only one column and AutoSizeColumnsMode set to Fill).

 

 

1 Answer, 1 is accepted

Sort by
0
Accepted
Dess | Tech Support Engineer, Principal
Telerik team
answered on 25 Jan 2018, 01:18 PM
Hello, Rohit,

Thank you for writing.  

In order to align the cell's content in RadVirtualGrid it is suitable to use the CellFormatting event and change the CellElement.TextAlignment property:
private void radVirtualGrid1_CellFormatting(object sender, Telerik.WinControls.UI.VirtualGridCellElementEventArgs e)
{
    e.CellElement.TextAlignment = ContentAlignment.MiddleLeft;
}

I hope this information helps. Should you have further questions I would be glad to help. 
 
 Regards,
Dess
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
VirtualGrid
Asked by
Rohit
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or