Hi, I'm trying to put it in the default.JSS file. Thanks, Scott -----Original Message----- From: jawsscripts-bounce@xxxxxxxxxxxxx [mailto:jawsscripts-bounce@xxxxxxxxxxxxx] On Behalf Of Paul Magill Sent: Saturday, 24 May 2008 5:53 PM To: jawsscripts@xxxxxxxxxxxxx Subject: [jawsscripts] Re: to make laptop battery say Hi Scott, Sounds like the .jss file in which you have the script, may not have a include "HJConst.jsh" line at the top??? without including that file, the OT_User_Requested_Information constant = will not be recognised by the compiler. Regards, Paul from Aust ----- Original Message -----=20 From: "Scott Erichsen" <pianoman@xxxxxxxxxxxxxxxxx> Doug, Thanks for this, but it still won't compile. I have put a blank line = before and after the lines that are refusing to compile. I didn't think OT_USER_REQUESTED_INFORMATION was a variable script sayBatteryLevel() var handle hwnd if !isSameScript() then performScript sayBatteryLevel() return endIf let hwnd =3D findTopLevelWindow("SystemTray_Main", "") if hwnd then let hwnd =3D getLastWindow(getFirstChild(hwnd)) ; Dialog containing details let hwnd =3D getFirstChild(hwnd) while hwnd && !stringContains(getWindowName(hwnd), "%") let hwnd =3D getNextWindow(hwnd) endWhile if stringContains(getWindowName(hwnd), "%") then ; Say total remaining battery power percentage, even if on AC power. sayMessage(OT_User_Requested_Information, getWindowName(hwnd)) ; Then say "AC Power" or "Batteries" to indicate which is in effect. sayMessage(OT_User_Requested_Information, getWindowName(getNextWindow(hwnd))) endIf let hwnd =3D getLastWindow(hwnd) ; Time remaining sayMessage(OT_User_Requested_Information, getWindowName(hwnd)) return endIf performScript sayBatteryLevel() endScript __________=A0 View the list's information and change your settings at=20 http://www.freelists.org/list/jawsscripts __________ View the list's information and change your settings at http://www.freelists.org/list/jawsscripts