Hi David & Don,
I think I could suggest you two other methods to maximize a window.
1. Use SendMessage function. Insert this line in the AutoStart event:
SendMessage(GetAppMainWindow(GetFocus()), 274, 61488, 0). It will
maximize the active window.
2. Use some workaround. It is a simpler method. It needs some refining,
because I write it down from memory. This script toggles window state
between maximized and normal. But you can extend it so, that it supports
only maximized and minimized state.
This script works in all windows having system menu. The menu you can
call with Alt+Space.
Script ToggleRestoreWindow ()
;This script make notepad maximize or restore
Var
String sName, String sShortname ;Get the name of currently open file
SpeechOff ()
TypeKey {Alt+space}
If GetControlAttributes (false)==4 then ;the Restore option is unavailable
TypeKey {x} ;send letter x to current application
Let sName=FormatString (Maximize_l, GetAppTitle ())
Let sShortname=FormatString (Maximize_s, GetAppTitle ())
Else ;windows is currently maximize
EnterKey ()
Let sName=FormatString (restore_l, GetAppTitle ())
Let sShortname=FormatString (restore_s, GetAppTitle ())
EndIf
Pause ()
SpeechOn ()
SayFormattedMessage (ot_message, sName, sShortName)
EndScript
HTH
Csaba
For answers to frequently asked questions about this list visit:
http://www.jaws-users.com/help/