

For child windows you'd use enumchildwindows in a similar way.
Visual basic for applications access code#
The code below should print out all top-level window titles. EnumChildWindows continues until the last child window is enumerated or the callback function returns FALSE." "The EnumChildWindows function enumerates the child windows that belong to the specified parent window by passing the handle to each child window, in turn, to an application-defined callback function.

RE: Accessing Windows ssmgr (TechnicalUser) So come on all you API wizards show me how it's done - PLEASE. BUT its two and a half inches thick!! At my reading speed it'll be time for the 2008 Olympics before I get close. I just yesterday bought a copy of Dan Appleman's Visual Basic Programmer's Guide to the Win32 API. Ergo I'm hoping to circumvent the problem by fooling XP into thinking that the operator is keying into Outlook Express directly. But I need to create an semi-automatic solution. However, you can open a new message window and if you manually switch to that window you can fill in the fields and send an email without a hitch. MS security features in these later OSs refuse to allow access to the mail client. The reason for all this is because the DoCmd.SendObject method to send an email from Access97 via the default mail client (Outlook Express in my case) does not work under Win2000 or XP. If possible, when that's all done I'd like to either locate the Send button on the form and send a click to the button to send the email or switch to that window so the user can view the results and click Send. For each of these child windows I need to send some text (typically from an Access97 module). I then need to locate child windows within that form in the order of To: line, Subject: line and message body. To be specific "New Message", being the title of a new Outlook Express message window before the subject line is filled. This callback function receives a windows handle. The function needs the address of a function that is called for each window until all windows are iterated over or the function returns false. The WinAPI function EnumWindows can be used to iterate over all windows. I need to locate an open window with a known name. Examples for Visual Basic for Application accessing the Windows API: EnumWindows. So I thought I'd piggy back onto yours and with a bit of luck some kind soul will.
