SpUtils - Rexx Utility Package - Reference Manual

By Tim Mecking

spUtils Rexx Utility Package

Reference Manual

Preview Release 1 © 2004 by mecking.net spUtils Preview Release 1 Reference Manual

Software license
If you use spUtils.dll or any other file from the archive you agree to these terms.

The files are licensed, not sold. You obtain no rights other than those granted to you under this license.

This license permits you to: You may not sublicense, rent or lease the files.
 * 1) use the files on one or more machines, even at the same time.
 * 2) make copies of the files.
 * 3) redistribute the archive at no charge.

There is no warranty that the files are free from claims by a third party of copyright, patent, trademark, trade secret, or any other intellectual property infringement.

The author or authors are under no circumstances liable for any of the following:
 * 1) third-party claims against you for losses or damages.
 * 2) loss of, or damage to, your records or data.
 * 3) economic consequential damages (including lost profits or savings) or incidental damages, even if we are informed of their possibility.

There is no warranty that the provided informations are correct, or that the programs operate uninterrupted or error free.

If you do not agree to any of the above terms and conditions, or if any of the above terms and conditions are not legal due to local/country laws you are not granted a license and may not use the files.

IBM, OS/2, Presentation Manager, and Workplace Shell are trademarks or service marks of IBM Corporation.

Serenity Systems, eCS, and eComStation are trademarks of Serenity Systems International Other company, product, and service names may be trademarks or service marks of others.

Requirements
required: spUtils should work on any OS/2 or eComStation system which supports the Open32 API.

useful: XRay by CodeSmith Software is very useful when writing scripts using the PM API functions. It shows informations about the window control under the mouse cursor. You'll find it at hobbes: xray10.zip. PMTree by IBM is even more powerful. It not only shows informations about window controls, but also allows to edit them. It's also on hobbes: pmtree30.zip.

Installation
Copy spUtils.dll into any directory listed in your libpath, e.g. \OS2\DLL on your boot volume.

Release Notes
This release is called “Preview Release 1”. Several functions still need to be implemented. But it is already quite usable and most of the features are not available in other Libraries. For example Alessandro Cantatore wrote on his TABTRAY page, that he first wanted to write a REXX script for XCenter tray switching. With this library this would be possible. Or Innotek wrote in the readme of OS/2 Kit for Java, that REXX scripts cannot access the registry by default. Right, not by default, but by the use of this library&#39;s spRegistry function it is possible.

Base

 * spLoadFuncs
 * spDropFuncs
 * spVersion
 * spSetAutoSleep
 * spD2X

DOS API Functions

 * spQuerySysInfo
 * spSleep
 * spKillProcess

Functions related to DOS API

 * spKillAll
 * spGetPidList
 * spFilenameFromPid
 * spGetBootdrive

PM API WinDialogs Functions

 * spQueryDlgItemText
 * spQueryDlgItemTextLength
 * spSetDlgItemText

PM API WinInput Functions

 * spQueryCapture
 * spQueryFocus
 * spSetFocus

PM API WinMessageMgr Functions

 * spPostMsg

PM API WinPointers Functions

 * spQueryPointerPos
 * spSetPointerPos

PM API WinSys Functions

 * spQuerySysValue

PM API WindowMgr Functions

 * spIsChild
 * spIsControlEnabled
 * spIsMenuItemChecked
 * spIsMenuItemEnabled
 * spIsMenuItemValid
 * spIsWindow
 * spIsWindowEnabled
 * spIsWindowShowing
 * spIsWindowVisible
 * spQueryActiveWindow
 * spQueryButtonCheckstate
 * spQueryLboxCount
 * spQueryLboxSelectedItem
 * spQueryWindow
 * spQueryWindowPos
 * spQueryWindowText
 * spSetWindowText
 * spWindowFromID

Functions related to PM API

 * spFindWindowHandle
 * spFindWindowHandles
 * spMPFROM2SHORT
 * spMPFROMSH2CH
 * spQueryWindowID

WIN API Registry Functions

 * spRegistry