Tim Burgess wrote:
1 - Key bindings using modifiers. I know how to do this in VB, but I think
VB Script is slightly different. Is there a sample script anywhere that
demonstrates how to set up a shortcut key like Ctrl+Shift+F5?
You can register a hotkey like this:
Dim myKey : Set myKey = Keyboard.RegisterHotkey("Control-Shift-F5",
"MyFunction")
If you want to monitor when a specific key is pressed that's not defined
through RegisterHotkey, you can use the Keyboard.OnKeyProcessedUp event:
ConnectEvent Keyboard, "OnKeyProcessedUp", "MyFunction"
Sub MyFunction(keyCode, keyModifier)
If keyCode = vk_F5 And keyModifier = (kmControl Or kmShift) Then
' Control-Shift-F5 was pressed
End If
End Sub
Note that the Or in "kmControl Or kmShift" is a bitwise Or that ands the
two items together, meaning that the key modifier must be a Control plus
a Shift.
With OnKeyProcessedUp, the application will see the key before you do,
and you can't modify the behavior. If you're interested in modifying the
behavior of the key press, then look at OnKeyUp and OnKeyDown.
2 - I need to be able to read a lot of sub-windows on demand, so I'm looking
for a method of reading a window by passing a control ID as a parameter. If
anybody knows of any of the scripts that demonstrate this it'll get me off
to a flying start.
Are the class names of these windows unique? If so, you can use that.
Otherwise, you'll need to determine some other unique identifier of a
window. Look at a Window object for all the details.
HTH,
Aaron
--
To insure that you receive proper support, please include all past
correspondence (where applicable), and any relevant information
pertinent to your situation when submitting a problem report to the GW
Micro Technical Support Team.
Aaron Smith
GW Micro
Phone: 260/489-3671
Fax: 260/489-2608
WWW: http://www.gwmicro.com
FTP: ftp://ftp.gwmicro.com
Technical Support & Web Development