Where can I learn how to work with listview control (and I'm not talking about MSDN), without mfc, just plain API.
Thanks.
Where can I learn how to work with listview control (and I'm not talking about MSDN), without mfc, just plain API.
Thanks.
"I don't suffer from insanity but enjoy every minute of it" - Edgar Allen Poe
http://www.Bloodware.net - Developing free software for the community.
Did somebody say MSDN?
gg
Or at least google. Not to sound like a complete jerk, but browsing about google with a few different key terms should revela any info you may need.
Also, the above poster is correct. MSDN is your one-stop shopping spot for all of your API needs.
Well I did search at google, but it only finds mfc related places, but I need to write it in C with API.
And I don't want to go to msdn right away, because it's too dry, too technical. So I want to read on this control first, from a tutorial, and only then go to the msdn.
"I don't suffer from insanity but enjoy every minute of it" - Edgar Allen Poe
http://www.Bloodware.net - Developing free software for the community.
Mmmm, if only more resources were dry and technical.....
MSDN also has sample downloads.
gg
I just started using list views again. Here's some example code:
Note: include <commctrl32.h>, and link with comctl32.lib. Before you create the control, run InitCommonControls().Code:HWND hList; hList=CreateWindowEx(WS_EX_CLIENTEDGE,WC_LISTVIEW,NULL,WS_CHILD|WS_VISIBLE | WS_BORDER | LVS_REPORT,0,0,300,300,hwnd,(HMENU)ID_LIST,GetModuleHandle(NULL),NULL);
Code:LV_COLUMN lvc; lvc.mask=LVCF_FMT | LVCF_TEXT | LVCF_WIDTH; lvc.fmt=LVCFMT_LEFT; lvc.cx=100; lvc.pszText="Privilege"; SendMessage(hList,LVM_INSERTCOLUMN,0,(LPARAM)&lvc); //Insert sub item column lvc.mask=LVCF_FMT | LVCF_TEXT | LVCF_SUBITEM | LVCF_WIDTH; lvc.iSubItem=1; lvc.pszText="Attributes"; lvc.cx=300; SendMessage(hList,LVM_INSERTCOLUMN,1,(LPARAM)&lvc); //Insert item LV_ITEM lvi; lvi.mask=LVIF_TEXT; lvi.iItem=0; lvi.iSubItem=0; lvi.iImage=0; lvi.pszText="Text"; SendMessage(hList,LVM_INSERTITEM,NULL,(LPARAM)&lvi); //Insert sub-item lvi.mask=LVIF_TEXT; lvi.iItem=0; lvi.iSubItem=1; lvi.pszText="ATTRIBUTE"; SendMessage(hList,LVM_SETITEM,NULL,(LPARAM)&lvi);
[email protected]
Microsoft Visual Studio .NET 2003 Enterprise Architect
Windows XP Pro
Code Tags
Programming FAQ
Tutorials
yes it does, but it's not what I'm looking for... I'm looking for a control that looks like a window with "details" (VIEW->DETAILS)Mmmm, if only more resources were dry and technical.....
MSDN also has sample downloads.
That's why what bennyandthejets gave me is exactly what I need.
Thanks a lot to everyone. I've been searching for this thing for quite a while, and finally got it.
Last edited by Devil Panther; 07-12-2003 at 02:10 AM.
"I don't suffer from insanity but enjoy every minute of it" - Edgar Allen Poe
http://www.Bloodware.net - Developing free software for the community.
Run a search here for 'listview'. Plenty of code for WIN32 C listviews.
"Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
Friedrich Nietzsche
"I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
George Best
"If you are going through hell....keep going."
Winston Churchill