We help IT Professionals succeed at work.

Vb. Net Programmatically format datagrid columns

rflorencio
rflorencio asked
on
Medium Priority
374 Views
Last Modified: 2012-05-12
I have a datagridview that loaded dynamically through a datatable. Columns come from multiple tables and not have the same name. What was intended is to format the column in the grid, depending on the datatype of column data in datatable. Eg. if data type decimal, is right-justified. If data type date, is centered. ...
Comment
Watch Question

Commented:
Have a look at DataGridView1.Columns().DefaultCellStyle...

Commented:
On re-read, plusone's comment is probably going to work better since you will be doing multiple, if not all columns.

Explore More ContentExplore courses, solutions, and other research materials related to this topic.