What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » Visual Basic Code Help

Visual Basic Code Help
Author: Message:
CookieRevised
Elite Member
*****

Avatar

Posts: 15519
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: Visual Basic Code Help
quote:
Originally posted by DJeX
Ahh ok, I see what your saying. But because I want to learn this I still want to get it to work. Just for my own knoledge. Now your saying I should use EnumWindows() and EnumChildWindows() funtions right? Would they work the same as the GetWindow() and GetDesktopWindow()? Like for example:

CurHwnd = GetWindow(CurHwnd, GW_CHILD) < -- Original code.

CurHwnd = EnumWindows (CurHwnd, GW_CHILD) <-- Would that work?
nope... they are completely different. See the code in the Module for an example of EnumChildWindows()...

The enumuration functions use something which is called a "callback function" to work. The functions are called only once, and they in turn will call the function you provided as a parameter (hence the "callback") for each window they find.

For the complete detailed info about these API's (and any other API for that matter) see the msdn library and search for those API functions.

EnumWindows()
EnumChildWindows()

You should also never use the GetWindow() API for the purpose of enumerating/scrolling thru all the windows (hence the Form code isn't that good). Reasons for this can be read in the msdn library again.

This post was edited on 11-28-2005 at 12:27 AM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
11-28-2005 12:11 AM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Visual Basic Code Help - by DJeX on 11-27-2005 at 05:05 AM
RE: Visual Basic Code Help - by Mnjul on 11-27-2005 at 05:15 AM
RE: Visual Basic Code Help - by DJeX on 11-27-2005 at 05:38 AM
RE: Visual Basic Code Help - by Mnjul on 11-27-2005 at 05:56 AM
RE: Visual Basic Code Help - by DJeX on 11-27-2005 at 07:15 AM
RE: Visual Basic Code Help - by Mike on 11-27-2005 at 08:07 AM
RE: Visual Basic Code Help - by IKillThings on 11-27-2005 at 08:13 AM
RE: Visual Basic Code Help - by Mike on 11-27-2005 at 08:22 AM
RE: Visual Basic Code Help - by CookieRevised on 11-27-2005 at 10:21 AM
RE: Visual Basic Code Help - by DJeX on 11-27-2005 at 07:41 PM
RE: RE: Visual Basic Code Help - by CookieRevised on 11-27-2005 at 08:29 PM
RE: Visual Basic Code Help - by DJeX on 11-27-2005 at 09:44 PM
RE: Visual Basic Code Help - by CookieRevised on 11-27-2005 at 11:01 PM
RE: Visual Basic Code Help - by DJeX on 11-27-2005 at 11:50 PM
RE: Visual Basic Code Help - by CookieRevised on 11-28-2005 at 12:11 AM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On