Click to See Complete Forum and Search --> : How do find properties of controls of other applications?
OhYeahLach
Feb 28th, 2001, 05:42 PM
How do find properties of controls of other applications?
For example: Looking to find the properties (ID,Value,Text, Enabled, etc...) of a text box on Internet Explorer.
We found APIs to find the handle, coordindates, caption, class.
How DID you find the handle and control type?
You must send windowmessages to the control to get at the properties. I'm not quite sure how it works either, but I need to know how to find the handle & control type.
Gerco.
The GetWindowLong function will get the styles and extended styles.
Lord Orwell
Mar 3rd, 2001, 02:57 AM
a& = SendMessage(iCheck&, BM_GETCHECK, 0&, 0&)
would return the state of a checkbox, given the handle of it (iCheck). A lot of controls have similar constants. confusingly, list boxes and combo boxes have different constants.
ExtremePimpness
Mar 3rd, 2001, 03:31 AM
Lord Orwell you are up really early it is 4:30 herein indiana. :)
Not me though i haven't been to bed yet:)
Lord Orwell
Mar 3rd, 2001, 04:28 AM
im in a different time zone. (live near evansville) and i haven't been to bed yet either :)
ExtremePimpness
Mar 3rd, 2001, 04:31 AM
oh that is why :D
have you tried out the new browser thing that is being developed for this forum?
Sounds nice... do you know what the constant is for setting the passwordchar on textboxes?
Gerco.
Here it is
Private Const EM_SETPASSWORDCHAR = &HCC
Here is the full code.
Private Const EM_SETPASSWORDCHAR = &HCC
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
'Usage
SendMessage EditHwnd, EM_SETPASSWORDCHAR, byVal "*", 0
fatehi
Feb 22nd, 2005, 06:38 AM
a& = SendMessage(iCheck&, BM_GETCHECK, 0&, 0&)
would return the state of a checkbox, given the handle of it (iCheck). A lot of controls have similar constants. confusingly, list boxes and combo boxes have different constants.
Hi!
Would you please tell me a site or URL that contains the constant values? for example the value for BM_GETCHECK (that i need it but i cant find!!)
manavo11
Feb 22nd, 2005, 03:31 PM
The specific constant is :
Const BM_GETCHECK As Long = &HF0&
You can use the API Viewer to find the constants : http://www.activevb.de/rubriken/apiviewer/index-apiviewereng.html
:)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.