PDA

Click to See Complete Forum and Search --> : How do I add items in the listview


abdul
Sep 1st, 2001, 09:39 PM
I want to add an item in listview in a spicifc column but I can't find any way to do that. I have two header columns:

Macro MacroDescription

Now I want to add "Macro1" under the header "Macro" and "MacroDesc" under the header "MacroDescription". How do I do that? Is there anyway to do this without handling to "WM_NOTIFY" from its parent window?

Here is a little code but it is just adding the item under the first column:



LVITEM lvi;
lvi.mask = LVIF_TEXT LVIF_STATE;
lvi.pszText = "MacroDesc"
lvi.iItem = 0;
lvi.state = 0;
lvi.stateMask = 0;
lvi.iSubItem = 0;

ListView_InsertItem(lvhwnd, &lvi);


What do I change in there so that I correctly put the string under the second column?

Thanks:D

abdul
Sep 2nd, 2001, 01:15 PM
Come on guys:) Almost all the applications have this kind of listview with multicolumns.

That is urgent because the school are starting the day after tomorrow and I won't have much time to work on my program:(

abdul
Sep 3rd, 2001, 11:43 AM
So, nobody has any answer?