- This topic has 2 replies, 2 voices, and was last updated 14 years ago by String.
Viewing 3 posts - 1 through 3 (of 3 total)
-
AuthorPosts
-
January 20, 2010 at 6:39 pm #187282methodMember
Hi all .I wonder how i can copy all the items from “Add a Pal” search result? Is it a listbox or listview ?can i use the same code the copies room user names ? I be happy if some one show me how this can be doen.Thanks
January 22, 2010 at 1:47 am #187284StringMemberYeah, its a listview. With a few mods, I was able to use the same technique used to get room list to retrieve this list as well.
January 22, 2010 at 8:47 am #187283methodMemberThanks string for your reply. I used the following function to get listview hwnd but unfortunelty when i use that hwnd value to count the listview items i get zero. Could you tell me what i am doing wrong to get the number of liste view itemes?
Looking forward for your reply.Thankscode to count the listview items:
.ItemCount = SendMessage(lvWindow, LVM_GETITEMCOUNT, 0&, 0&) MsgBox "itemcount:" & .ItemCount Note:lvWindow is same as hwnd of listview
funcion to get listview hwnd value:
Function getNickListHwnd2() As Long 'Variables 'Dim mywindowclass As Long, wtlsplitterwindow As Long, atldd As Long Dim syslistview As Long Dim atlc As Long, atlcf As Long, atla As Long atlc = FindWindow("#32770", "Add a pal") syslistview = FindWindowEx(atlc, 0&, "SysListView32", vbNullString) MsgBox syslistview getNickListHwnd2 = syslistview End Function
room list code to get hWnd :
Private Sub Command1_Click() Dim dlggroupchatwindowclass As Long, wtlsplitterwindow As Long, cwndmembertree As Long 'Dim syslistview As Long dlggroupchatwindowclass = FindWindow("dlggroupchat window class", vbNullString) wtlsplitterwindow = FindWindowEx(dlggroupchatwindowclass, 0&, "wtl_splitterwindow", vbNullString) wtlsplitterwindow = FindWindowEx(wtlsplitterwindow, 0&, "wtl_splitterwindow", vbNullString) wtlsplitterwindow = FindWindowEx(wtlsplitterwindow, 0&, "wtl_splitterwindow", vbNullString) wtlsplitterwindow = FindWindowEx(wtlsplitterwindow, 0&, "wtl_splitterwindow", vbNullString) wtlsplitterwindow = FindWindowEx(wtlsplitterwindow, 0&, "wtl_splitterwindow", vbNullString) cwndmembertree = FindWindowEx(wtlsplitterwindow, 0&, "cwndmembertree", vbNullString) syslistview = FindWindowEx(cwndmembertree, 0&, "syslistview32", vbNullString) MsgBox syslistview Call GetListviewItem(syslistview) End Sub
-
AuthorPosts
Related
Viewing 3 posts - 1 through 3 (of 3 total)
- You must be logged in to reply to this topic.