How to determen the position of a column in the collection columns

  • Thread starter Thread starter JR
  • Start date Start date
J

JR

hi,

I tryd this one but it dosn't work

lv.Columns.IndexOf(lvch)



where lv is my listview and lvch is the columnheader of the listview



thanks
 
ColumnHeader.Index

hi,

I tryd this one but it dosn't work

lv.Columns.IndexOf(lvch)



where lv is my listview and lvch is the columnheader of the listview



thanks
 
With .NET Framework you can use the ColumnHeader.DisplayIndex property. With
..NET Framework 1.x, you need to use the Win32 API for the ListView control,
LVM_GETCOLUMNORDERARRAY message or similar (see the docs).

--

Best regards,

Carlos J. Quintero

MZ-Tools: Productivity add-ins for Visual Studio .NET, VB6, VB5 and VBA
You can code, design and document much faster.
Free resources for add-in developers:
http://www.mztools.com
 
thanks now It works

Carlos J. Quintero said:
With .NET Framework you can use the ColumnHeader.DisplayIndex property.
With .NET Framework 1.x, you need to use the Win32 API for the ListView
control, LVM_GETCOLUMNORDERARRAY message or similar (see the docs).

--

Best regards,

Carlos J. Quintero

MZ-Tools: Productivity add-ins for Visual Studio .NET, VB6, VB5 and VBA
You can code, design and document much faster.
Free resources for add-in developers:
http://www.mztools.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top