How do I align text for a single subitem in a ListView using C#?

Fueled picture Fueled · Feb 18, 2009 · Viewed 34.7k times · Source

I wasn't able to find an answer anywhere about this seemingly simple topic: is it possible to align text of a single subitem in a WinForms ListView control?

If so, how?

I would like to have text in the same column aligned differently.

Answer

Novpiar Effendi picture Novpiar Effendi · May 11, 2013

example :

listView1.Columns[1].TextAlign = HorizontalAlignment.Right;

will set Column's "1" alignment to right