REXXUTIL Information and Samples

Автор: Michael Lamb

Дата: 1993

Здесь приведен текст книги без примеров. Полный текст книги в формате txt можно скачать по этой ссылке.

The following attempts to better explain some of the powerful features
provided by OS/2 V2's dynamic link library; REXXUTIL.DLL (Rexx utility
functions). REXXUTIL functions are described in the online 'REXX Information'
reference and the 'OS/2 2.0 Technical Library Procedures Language/2 REXX
Reference' publication (order number S10G-6268). The information following is
intended to provide a more detailed description of some of the functions.

Plans for this information
--------------------------
Much of this file has changed since the first few attempts at compiling useful
REXXUTIL information. Plans are to place this information out on an IBM
Internal FORUM, (REXXOS2 FORUM) and the OS2REXX CFORUM which makes its way out
into the external customer world. Hopefully within a month or so of making it
available I've received any corrections/omissions from both IBMer's and
customers. Thereafter I plan to create an OS2EWS package that will contain
this text information with the sample CMD files as separate files. Also
I plan on including an INF formatted file of the information. I really do
want the information to be as accurate as possible before creating the INF
file so please report to me any items of omission or error.

Publications
------------
One should realize that many of the functions provided by REXXUTIL have
origins with Presentation Manager Winxxx calls. These publications are helpful
and be reviewed for more information:

S10G-6265 OS/2 PM Programming Reference Vol - 2
          Contains all the Winxxx calls, the Workplace Shell classes, and
          their _wpxxx messages. Also this is available as an online doc
          that comes with the OS/2 Toolkit.
S10G-6309 OS/2 System Object Model Reference
          Also an online doc that comes with the OS/2 Toolkit.
GBOF-2254 OS/2 Technical Redbooks (series of technical documents)
          GG24-3732 OS/2 V2 Volume 3: Presentation Manager & WPS
          GG24-3774 OS/2 V2 Volume 4: Application Development
ZB35-5100 The REXX Language: A Practical Approach to Programming,
          ISBN 0-13-780651-5

Some of the functions used/explained herein:

SysIni:
-------
Using REXXUTIL's SysIni function one can modify many settings of the WorkPlace
Shell as well as change other applications settings that make use of *.INI
files such as the system OS2.INI and OS2SYS.INI.

SysCreateObject: (PM WinCreateObject - Create Workplace Object)
----------------
Using REXXUTIL's SysCreateObject function one can create various objects;
like folders, programs, and shadow objects using Rexx. This section for the
most part includes parameter information which was gathered together from
various sources of information.

SysSetObjectData: (PM WinSetObjectData - Set Object Data)
-----------------
Using REXXUTIL's SysSetObjectData function one can change an objects
characteristics (of an already created object, if you know its objectid).

SysDestroyObject: (PM WinDestroyObject - Destroy Workplace Object)
-----------------
Using REXXUTIL's SysDestroyObject one can delete an object created if you
know its objectid.

Misc Notes:
If one views the *.RC files located in your bootdrive:\OS2 directory you
can learn a lot about the various INI settings and folder structure.
Review INI.RC and INISYS.RC files, they are used to create your OS2.INI
and OS2SYS.INI files. (Note in the *.RC files "?:" is used to indicate
the boot drive)

Some of REXXUTIL's functions are only available when using the very latest
REXX20 PACKAGE which consists of the very latest REXX fixes and enhancements
for GA OS/2 V2.0. Should you have problems running any of the sample programs
you should make sure your system has the vary latest REXX20 updates. In
addition to the REXX fixes, various OS/2 V2 base fixes may be needed as well.
You may need to install/apply the latest 2.0 Service Pack, or even OS/2 2.1 in
order for some of the operations to behave properly.

If anyone discovers other parameters or other "hidden" features of
any of the functions discussed, please share your discovery. I'll try to
update the information as I receive it.

Thanks...
Michael Lamb MIKELAMB(KGNVMC)         Michael Lamb
Workstation Technical Support         4 Cross Creek Rd
ISSC - MHV Solution Center            New Paltz, NY 12561-3805
30NC/370 Neighborhood Rd
Kingston NY 12401
(914)385-0666 t/l-695-0666

Change Log:
  04/30/92 - Added information about DuplicateFlag parm
           - Added more setup string information from manuals
  06/02/92 - Added information about breaking Title line character "^"
           - Added information about adding multiple DOS_DEVICE statements
           - Added code to SHADOW.CMD to make shadow object of a file
  !!NOTE!! - The REXXOS2 fixes are required to make some of
             the newer samples work properly.
  06/30/92 - Added information regarding two new REXXUTIL functions:
             SysSetObjectData and SysDestroyObject, also two new
             samples STARTDOS, BOOTDOS (Thanks to Rick McGuire)
  07/13/92 - Reorganized the way the material is presented. Also added more
             sample Rexx routines REBUILD, OBJCLASS and LPTADD, descriptions
             follow. Also changed parm CONCURRENTVIEW to CCVIEW (Thanks
             Dan Kehn, Felix Sawicki)
  07/15/92 - Updated entire document as I mistakenly truncated it at 80
             characters. Rewrote some sample Rexx routines so they do not
             extend beyond 80 characters. Also updated the SysSetObjectData
             description to show how can open an object (Thanks Rick). Added
             information about creating multi-line titles, carat works for
             two line titles but not more than 2.
             New samples, OBJECTID and FONTS included, descriptions follow.
  07/29/92 - Corrected an error I made when I broke the setup lines into
             multiple lines. I needed to add ]]'s to make sure they
             concatenated without spaces (Thanks Rick). Also added
             information regarding changing some System Settings (added
             new section after sample Rexx code). Also added warning
             in REBUILD.CMD sample about replacing Folder objects. Also
             added new sample ICONRES.CMD which builds a folder containing
             many of the OS/2 V2 installed icons using system DLL files.
  01/30/93   Added to some examples the use of SysDestroyObject to clean up
             after creating objects, also added the syntax for the call.
             Changed REBUILD.CMD sample to used 'U' for updateifexists as
             the duplicateflag to prevent problems. Added warning about
             the 'R' duplicateflag parameter to field description.
             Added information about changing Background tab, Change color
             button values. Changed OBJECTID.CMD to enclose results in
             double quotes to easier distinguish results.
             Changed descriptions of calls to better match what's found in the
             toolkit documentation for the Winxxx calls.
  04/11/93   Added some information in ASSOCTYPE, ASSOCFILTER section.
             Added new PROGTYPE values. Added ICONVIEWPOS information.
  07/04/93   Too many changes to note. Lots having to do with OS/2 V2.1

This append consists of multiple pieces of information:

1) Large block of text containing information that pertains to the subject.
   (TEXT INFORMATION)
2) Sample Rexx code, some complete programs, others code fragments:
 - (FOLDER.CMD)
   Creates a folder and program objects in the folder
 - (SHADOW.CMD)
   Creates shadows of objects
 - (FLDSHAD.CMD)
   Creates a folder, then program object in the folder, then place a shadow
   of the program object on the desktop.
 - (MKSHAD.CMD)
   Creates a shadow object of an objectid, file or drive/directory.
 - (STARTDOS.CMD)
   Starts a DOS program using specific DOS VDM settings.
 - (BOOTDOS.CMD)
   Starts a DOS session, booting from a specific DOS image with
   specific DOS VDM settings.
 - (REBUILD.CMD)
   Allows one to rebuild OS/2 system objects, kinda like MAKEINI does.
 - (LPTADD.CMD)
   Code using SysIni to add LPT4-9 ports.
 - (OBJECTID.CMD)
   Code using SysIni to list OBJECTIDs known to the WorkPlace Shell
 - (FONTS.CMD)
   Code using SysIni to list installed fonts and verify their existence.
 - ICONRES.CMD
   Code building a folder containing many of the various icons found in
   installed DLL files for OS/2 V2. Demonstrates use of setup string
   parameter ICONRESOURCE.
 - SWAPEDIT.CMD
   Code that allows you to make the Enhanced Editor (EPM) the default open
   action for most data objects instead of the OS/2 Enhanced Editor (E).
 - OPENWPS.CMD
   Code that allows you to open up an objectid or directory using views
   you specify.
3) Code Fragments
 - (SYSSET)
   Shows using SysIni to toggle various System Settings

((BEGIN TEXT INFORMATION))
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-- Information regarding the SysCreateObject function of REXXUTIL --

Function: SysCreateObject
Syntax:
result=SysCreateObject(classname, title, location <,setup>,
 classname: The name of the class of which this object is a member.

 title:    The object title, as it is to appear when displayed on the user
           interface underneath an icon or on the title bar of an open object.
           (Note this can be changed later using the TITLE keyword)

 location: The object location. This can be specified as either an
           object ID (for example,
) or a file system path
           (for example, C:\bin\mytools).
           (Object ids will be explained later)

 setup:    A WinCreateObject setup string. Described more later on.

 duplicateflag: This parameter indicates what action should be taken
           when the Setup string specifies an object ID, and an object with
           that object ID already exists. If the setup string does not give
           an object ID, another object will be created.

 result    The return code from WinCreateObject. This returns 1 (TRUE) if the
           object was created and 0 (FALSE) if the object was not created.

 Purpose:  Create a new instance of an object class.

-- Information regarding the SysSetObjectData function of REXXUTIL --

Function: SysSetObjectData
Syntax:
result=SysSetObjectData(name, setup)

 name:     The object name. This can be specified as an object id (for
           example
) or as a fully qualified file name.

 setup:    A WinCreateObject setup string. Described more later on.

 result:   The return code from WinSetObjectData. This will return 1 (TRUE)
           if the object was updated and 0 (FALSE) if the object was not
           updated.

 Purpose:  Alter the settings of an existing object.

           Can be used to open an instance of an object:
           /* open up the system folder */
           call SysSetObjectData '
', 'OPEN=DEFAULT;'

           Can be used to change the title of an object:
           /* change Information folder name */
           call SysSetObjectData '
', 'TITLE=InfoFolder'

See the description of the SysCreateObject location and setup strings
following for an explanation of the parameters.

-- Information regarding the SysDestroyObject function of REXXUTIL --

Function: SysDestroyObject
Syntax:
result=SysDestroyObject(name)

 name:     The object name. This should be specified as an object id, for
           example
. It can also be a fully specified file name.

 result:   The return code from WinDestroyData. This will return 1 (TRUE)
           if the object was destroyed and 0 (FALSE) if the object was
           not destroyed.

 Purpose:  Delete an existing workplace object, or file.

See the description of the SysCreateObject location parameter
following for an explanation of the object name. See the OBJECTID.CMD sample
for a way to determine the objectid's the system knows about.

--Parameters Explained-------------------------------------------------------

Parameters to the functions are now explained in more detail.

classname:
  A registered object class defined to the system. Of particular interest are
  the WPFolder/WPProgram/WPShadow classes. Note using the sample Rexx code
  included in the SysQueryClassList function help screen one can list all
  of the registered classes:

  call SysQueryClassList "list."
  do i = 1 to list.0
     say 'Class' i 'is' list.i
  end

title:
  The objects title you want to use. If you wish to break the title line you
  use a comma "," as the line break character. However, there were problems
  with this and it may or may not work depending on whether you have the
  latest REXX and OS/2 V2 fixes installed. You may instead decide to use
  a hex 0A character (line-feed) in the string to separate lines.

  Rexx example:  Note: x2c is Rexx's hex to character function.

  title='First'x2c(A)'Second'x2c(A)'Third'

  Note if you wish to use the special characters; comma or semi-colon in the
  string, prefix the character with the carat symbol.

  Example title, you want:
  ] My Activities     ]   you would use...
  ] December 25, 1992 ]     title='My Activities,December 25^,1992'

location:
  The objects location can be specified as either an existing object id,
  for example
, or alternatively a fully qualified file name of
  any file or directory.

  An object id string must always start with the '<' character and be
  terminated by the '>' character and is thus an invalid file system name.

  By looking at your \OS2\INI.RC file you can see a use of many object ids
  such as
. If this is used as a location then your object will
  be placed on the WorkPlace Shell desktop.

  If you are creating an object you should make sure you use the OBJECTID
  setup string parameter and give that object a unique object id. We'll see
  how this works later.

  HINTS: Here are some predefined object ids of system folders. Also if you
         are thinking of placing an object in the Startup Folder
,
         make it a shadow of an object.
        
   Desktop
        
     Startup folder
        
    OS/2 System folder
        
     Templates folder
        
    System Setup folder
        
      Information folder
        
    Drives folder
        
   Hidden folder
        
   Command Prompts folder
        
     Productivity folder
        
     Games folder
         ---Some other common OS/2 folder objectids---
        
   Mahjongg folder
        
Multimedia folder
        
Multimedia Sound Bites folder
        
Multimedia Movies folder
        
   Toolkit 2.1 folder
        
   Toolkit Information folder
        
  Development Tools folder
        
   Sample Programs folder

setup:
  This field needs the most explaining. Each object class, WPProgram,
  WPFolder, etc, documents its setup string keynames and parameters.
  A larger section follows that details many of the available keynames and
  parameters. The setup string contains a series of "keyname=value" pairs,
  that change the behavior of the object. "keynames" are separated by
  semicolons, and "values" are separated by commas.

    "key=value;key2=value1,value2;"

  If you want a literal comma or semicolon inside one of your fields you
  must precede the comma/semi-colon with a carat as in the following:
      ^,   A literal comma
      ^;   A literal semicolon

  Note that ALL setup string parameters have safe defaults, so it is never
  necessary to pass unnecessary parameters to an object.

  (Note: The setup string was limited to a total length of 255 bytes in the
         2.0 GA code, this limitation is removed if the Service Pack is
         applied or you are using OS/2 2.1) (APAR PJ02271)

duplicateflag:
  There are three possible values for this parameter:
  FailIfExists - No object should be created if an object with the
      given object already exists. This is the default and maps to the
      PM creation flag, CO_FAILIFEXISTS
  UpdateIfExists - If an object with the given object ID already exists,
      the existing object will be updated with the new setting information.
      Maps to the creation flag, CO_UPDATEIFEXISTS. If the object does
      not exist, it is created.
  ReplaceIfExists - If an object with the given object ID already exists,
      the existing object should be replaced. Maps to the PM creation
      flag, CO_REPLACEIFEXISTS.
  WARNING: Be careful using the 'R' ReplaceIfExists value. Any attempt to
           rebuild an object first deletes any object that is using that
           same
. This can be useful if you want to restore an
           object back to its original installed state. This can also be
           bad since if you rebuild a folder it first deletes all objects
           in it since those objects are tied to the folder object.
  Note: Only the first character is required/examined, i.e. F, R, or U

--Setup Strings--------------------------------------------------------------

  Using WPFolder and WPProgram classes in your SysCreateObject call you can
  build folder and program objects. What follows are setup string parameters.
  Their various key names, values, and a short description follow
  each item. The < items are used to indicate what Workplace Shell
  settings "page" you would find this information on.

  An instance of each class is created initially by the system in its
  template form. It has the title "Folder" / "Program", respectively, and
  resides in the systems "Templates" folder.

*********************************
***WPFolder setup string parms***
*********************************
KEYNAME      VALUE           Description
-----------------------------------------------------------------------------
<
OPEN         ICON            Open icon view when object is created/updated.
             TREE            Open tree view when object is created/updated.
             DETAILS         Open details view when object is created/updated.
           Example:
             /* Open up the tree view of the system folder */
             call SysSetObjectData '
', 'OPEN=TREE;'
ICONVIEW     s1Х,s2,...snе   Set icon view to specified style(s).
TREEVIEW     s1Х,s2,...snе   Set tree view to specified style(s).
DETAILSVIEW  s1Х,s2,...snе   Set details view to specified style(s).
(styles)     FLOWED          flowed list items
             NONFLOWED       non-flowed list items
             NONGRID         non-gridded icon view
             NORMAL          normal size icons
             MINI            small icons
             INVISIBLE       no icons
             LINES           lines in tree view
             NOLINES         no lines in tree view
ICONFONT     value           Font size and facename. See Font Notes following.
TREEFONT     value           Font size and facename. See Font Notes following
DETAILSFONT  value           Font size and facename. See Font Notes following
(Font Notes)
The format for the value is normally;   size.facename fontstyle hex0
  example:   8.Courier Bold
  Remember the value should end with null zero.
  Example code to change the Information Folder icon view font:
    call SysSetObjectData '
', 'ICONFONT=8.Courier Bold'x2c(0)

We say 'normally' because there are certain circumstances where you must
separate values using a period. Also if you use a font style of 'Normal'
you just leave off the font style (don't use the word 'Normal')
Following is a small table to help.

FaceName: Courier FontStyle: Normal
  'ICONFONT=8.Courier'x2c(0)
FaceName: Courier FontStyle: Bold Italic
  'TREEFONT=8.Courier Bold Italic'x2c(0)
10 FaceName: System Proportional FontStyle: Bold
  'DETAILSFONT=10.System Proportional.Bold'x2c(0)

HINT: To find out what the string should look like, create a folder, name it
      simple like MYFOLD, then manually change the font size/name using the
      Open/Settings/Change font button. Close the settings, then from an
      OS/2 command line first determine the name of your desktop, for a
      typical 2.0 FAT file system it would be something like C:\OS!2_2.0_D
      (It gets easier for 2.1 where the Desktop is normally named C:\DESKTOP)
      Then locate the folder you created C:\OS!2_2.0_D\MYFOLD
      Then enter:  EAUTIL C:\OS!2_2.0_D\MYFOLD MYFOLD.EAS /S /P
      This will create a MYFOLD.EAS file, use a browse program to view this
      file and you'll see the values required.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
BACKGROUND   filename        Sets the folder background. filename is the
                             name of a file in the \OS2\BITMAP directory
                             of the boot drive.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
WORKAREA     YES             Make the folder a Workarea folder
             NO
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
HIDEBUTTON   YES             Views of this object will have a hide button
                             as opposed to a minimize button.
             NO              Views of this object will have a minimize button
                             as opposed to a hide button.
MINWIN       HIDE            Views of this object will hide when their
                             minimize button is selected.
             VIEWER          Views of this object will minimize to the
                             minimized window viewer when their minimize
                             button is selected.
             DESKTOP         Views of this object will minimize to the
                             Desktop when their minimize button is selected.
CCVIEW       YES             New views of this object will be created every
                             time the user selects open.
             NO              Open views of this object will resurface when
                             the user selects open.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<

** See General and Miscellaneous section following ***

-----------------------------------------------------------------------------

**********************************
***WPProgram setup string parms***
**********************************
KEYNAME      VALUE           Description
-----------------------------------------------------------------------------
<
EXENAME      filename        Sets the name of the program
PARAMETERS   params          Sets the parameters list, which may
                             include substitution characters
                             ---Substitution characters---
                             Special substitution parameters are allowed:
                             Х е     :(bracket blank bracket) You are prompted
                                      to type any parameters you want to use.
                             Хtextе  :Characters placed inside of the brackets
                                      are displayed as the prompt string.
                             no parm :If the program object is started by
                                      clicking on it no parameters are passed.
                                      If you start the program object by
                                      dragging a file over it, the full
                                      filename is passed.
                             %       :No parameters are passed. Useful for
                                      program objects you may want to start
                                      from a folders pop-up menu.
                             %*      :Like passing no parms, but useful if you
                                      need to insert the filename of a dragged
                                      object somewhere other than at the end
                                      of the parameter list.
                             %**P    :Insert drive and path information without
                                      the last backslash (\).
                             %**D    :Insert drive with ':' or UNC name.
                             %**N    :Insert file name without extension.
                             %**F    :Insert file name with extension.
                             %**E    :Insert extension without leading dot. In
                                      HPFS, the extension always comes after
                                      the last dot.
                             REMEMBER: If you specify a parameter in the field
                                       the name of any file being dragged onto
                                       this object is added to the end of the
                                       parameter list.
STARTUPDIR   pathname        Sets the working directory
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
PROGTYPE     OS/2 session values:
             PM              Sets the session type to PM
             FULLSCREEN      Sets the session type to OS/2 full screen
             WINDOWABLEVIO   Sets the session type to OS/2 windowed
             DOS session values:
             VDM             Sets the session type to DOS full screen
             WINDOWEDVDM     Sets the session type to DOS windowed
             WIN-OS/2 session values:
             WIN             WIN-OS2 full screen
             WINDOWEDWIN     WIN-OS2 windowed, NOT a separate VDM session
             SEPARATEWIN     WIN-OS2 windowed, Separate VDM session
             -- Values for OS/2 2.1 systems --
             PROG_31_STD     WIN-OS2 full screen, Windows 3.1 Standard mode.
             PROG_31_STDSEAMLESSVDM
                             WIN-OS2 windowed, Separate VDM session,
                             3.1 Standard mode
             PROG_31_STDSEAMLESSCOMMON
                             WIN-OS2 windowed, NOT a separate VDM session,
                             3.1 Standard mode
             PROG_31_ENH     WIN-OS/2 full screen, NOT a separate VDM session,
                             3.1 Enhanced Compatibility
             PROG_31_ENHSEAMLESSVDM
                             WIN-OS2 windowed, Separate VDM session,
                             3.1 Enhanced Compatibility
             PROG_31_ENHSEAMLESSCOMMON
                             WIN-OS2 windowed, NOT a separate VDM session,
                             3.1 Enhanced Compatibility
MINIMIZED    YES             Start program minimized
MAXIMIZED    YES             Start program maximized
NOAUTOCLOSE  YES             Leaves the window open upon program termination.
             NO              Closes the window when the program terminates.
SET          XXX=VVV         XXX is any environment variable. VVV sets the
                             value of the environment variable. When used will
                             wipe out many variables you may have assumed were
                             set. Check environment space closely when using.
                             Also used to specify DOS settings for DOS and
                             Windows programs. --See next section--
----------------------------
- DOS and WIN-OS2 Settings -
----------------------------
IMPORTANT NOTES:
1) To change these values you use SET keyname=
  Example:   SET DOS_FILES=45;SET DOS_HIGH=1;
  Also for some use values of 1 for On, 0 for off
  Example:   SET COM_HOLD=1;     (on, default is off)
2) To add more than one line to a setting you can use the same technique used
  to have more than one title line. See the discussion previous regarding
  that technique. Here's an example using the DOS_DEVICE keyname:
  Rexx example:
  setup='...;SET DOS_DEVICE=C:\OS2\MDOS\ANSI.SYS'x2c(A)'C:\OS2\MDOS\EGA.SYS...'
3) Some settings may already have default values, like DOS_VERSION. You must
  be careful since any action against that setting is treated as a
  replacement (even if you are using the updateifexist duplicateflag value).
  So if you wanted to add one item to DOS_VERSION, you should also include all
  of the existing values.
4) Some settings are new once you've installed the OS/2 V2 Service Pack or
  upgraded to OS/2 V2.1. As well some may not be on your workstation due to
  your hardware configuration, for instance use of VIDEO_8514A_XGA_IOTRAP
  is only available on certain systems.
5) WIN-OS2 Settings are new to V2 users and appear once the Service Pack is
  installed or you have upgraded to OS/2 V2.1. Refer to the section
  "Global WIN-OS2 Settings" for more information.

List of DOS and WIN-OS2 Setting fields
-----------------------------------------------------------------------------
Keyname                   Values and notes about usage
                          (<>'s are used to signify default setting for some)
                          (Remember 1=on and 0=off for those that us on/off)
-----------------------------------------------------------------------------
WIN_RUNMODE               Use the PROGTYPE parameter mentioned previously
                          to define a enhanced mode WIN-OS2 program (Also
                          see note 5 from above)
WIN_DDE                   (See note 5 above)
WIN_CLIPBOARD             (See note 5 above)
AUDIO_ADAPTER_SHARING     On Off
COM_DIRECT_ACCESS         On

COM_HOLD                  On
COM_RECEIVE_BUFFER_FLUSH  Valid settings:
                                           ALL
                                           RECEIVE DATA INTERRUPT ENABLE
                                           SWITCH TO FOREGROUND
COM_SELECT                Valid settings:
COM1 COM2 COM3 COM4 NONE
DOS_AUTOEXEC              C:\AUTOEXEC.BAT
                          Use full BATch filename also you can pass parameters
DOS_BACKGROUND_EXECUTION 
Off
DOS_BREAK                 On

DOS_DEVICE                Default: empty
                          Remember to separate any used with "," for newline
DOS_FCBS                  Limits: 0-255, default 16
DOS_FCBS_KEEP             Limits: 0-255, default 8
DOS_FILES                 Limits: 20-255, default 20
DOS_HIGH                  On

DOS_LASTDRIVE             Limits: last physical drive to Z, default Z
DOS_RMSIZE                Limits: 128-640, default 640, increments of 16
DOS_SHELL                 Default: "?:\OS2\MDOS\COMMAND.COM "
                                   "?:\OS2\MDOS\ /P" where ?
                                    is the boot drive
DOS_STARTUP_DRIVE         Default: empty
                          Accepts text; like A: or C:\DISKS\DRDOS.IMG
DOS_UMB                   On

DOS_VERSION               Default: DCJSS02.EXE,3,40,255
                                   DFIA0MOD.SYS,3,40,255
                                   DXMA0MOD.SYS,3,40,255
                                   IBMCACHE.COM,3,40,255
                                   IBMCACHE.SYS,3,40,255
                                   ISAM.EXE,3,40,255
                                   ISAM2.EXE,3,40,255
                                   ISQL.EXE,3,40,255
                                   NET3.COM,3,40,255
                                   EXCEL.EXE,10,10,4
                                   PSCPG.COM,3,40,255
                                   SAF.EXE,3,40,255
                                   WIN200.BIN,10,10,4
                          Remember what you put here will replace the existing
                          list of items so be careful, also remember to use
                          carats in front of any commas you need.
                          Example:
                          'SET DOS_VERSION=IBMCACHE.SYS^,3^,40^,255;']],...
DPMI_DOS_API              Valid settings:
  ENABLED  DISABLED
DPMI_MEMORY_LIMIT         Limits: 0-512, default 4
DPMI_NETWORK_BUFF_SIZE    Limits: 1-64, default 8
EMS_FRAME_LOCATION        Valid settings:
NONE C000 C400 C800 CC00
                                                      D000 D400 D800 DC00
                                                      8000 8400 8800 8C00 9000
EMS_HIGH_OS_MAP_REGION    Limits: 0-96, default 32, note increments of 16
EMS_LOW_OS_MAP_REGION     Limits: 0-576, default 384, note increments of 16
EMS_MEMORY_LIMIT          Limits: 0-32768, default 2048, note increments of 16
HW_NOSOUND                On

HW_ROM_TO_RAM             On
HW_TIMER                  On
IDLE_SECONDS              Limits: 0-60, default 0
IDLE_SENSITIVITY          Limits: 1-100, default 75
INT_DURING_IO             On

KBD_ALTHOME_BYPASS        On
KBD_BUFFER_EXTEND         Off
KBD_CTRL_BYPASS           Valid settings:
  ALT_ESC  CTRL_ESC
KBD_RATE_LOCK             On

MEM_EXCLUDE_REGIONS       Initially empty, you can specify a range of memory
                          to exclude or you can supply a singe address for the
                          beginning of a 4KB region, if you need several
                          regions separate them with a comma (don't forget to
                          use the carat since commas are special setup string
                          parameters) Example:
                          'SET MEM_EXCLUDE_REGIONS=C0000^,D0000-D8000;']],
MEM_INCLUDE_REGIONS       Initially empty, you can specify a range of memory
                          to include or you can supply a singe address for the
                          beginning of a 4KB region, if you need several
                          regions separate them with a comma (don't forget to
                          use the carat since commas are special setup string
                          parameters) Example:
                          'SET MEM_INCLUDE_REGIONS=C0000^,D0000-D7FFF;']],
                          NOTE: The include region D0000-D80000 will include
                                the entire memory between D8000 and D8FFFF.
MOUSE_EXCLUSIVE_ACCESS    On

NETWARE_RESOURCES         Valid settings: NONE  PRIVATE  GLOBAL
                          Special note, you use the words to change the value
                          BUT the string MUST be 7 characters long!
                          Example:
                          'SET NETWARE_RESOURCES=GLOBAL ;'
PRINT_SEPARATE_OUTPUT    
Off
PRINT_TIMEOUT             Limits: 0-3600, default 15
TOUCH_EXCLUSIVE_ACCESS    On Off
VIDEO_8514A_XGA_IOTRAP   
Off
VIDEO_FASTPASTE           On

VIDEO_MODE_RESTRICTION    Valid settings:   CGA  MONO
                          Special note, you use the words to change the value
                          BUT the string MUST be 15 characters long!
                          Example:
                          'SET VIDEO_MODE_RESTRICTION=CGA            ;'
VIDEO_ONDEMAND_MEMORY    
Off
VIDEO_RETRACE_EMULATION  
Off
VIDEO_ROM_EMULATION      
Off
VIDEO_SWITCH_NOTIFICATION On

VIDEO_WINDOW_REFRESH      Limits: 1-600, default 1
XMS_HANDLES               Limits: 0-128, default 32
XMS_MEMORY_LIMIT          Limits: 0-16384, default 2048, increment of 4
XMS_MINIMUM_HMA           Limits: 0-63, default 0
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
ASSOCFILTER  filters         Sets the filename filter for files
                             associated to this program.
                             Multiple filters are separated by commas.
                             See notes about preserving existing filter
                             values following.
ASSOCTYPE    type            Sets the type of files associated to this
                             program. Multiple filters are separated
                             by commas.
                             See notes about preserving existing associate
                             types following.
* Preserving existing values *
  When using ASSOCFILTER and/or ASSOCTYPE include two commas at the end of
  your string to preserve any settings that are already applied:
  Example: ... ASSOCTYPE=Metafile,PIF file,,;ASSOCFILTER=*.MET,*.PIF,,; ...
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<
MINWIN       HIDE            Views of this object will hide when their
                             minimize button is selected.
             VIEWER          Views of this object will minimize to the
                             minimized window viewer when their minimize
                             button is selected.
             DESKTOP         Views of this object will minimize to the
                             Desktop when their minimize button is selected.
CCVIEW       YES             New views of this object will be created every
                             time the user selects open.
             NO              Open views of this object will resurface when
                             the user selects open.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<

** See General and Miscellaneous section following ***

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
**General and Miscellaneous**
  NOTE: Some keynames are valid for any objects. Here in this section many of
  them are described. These can be used for the WPFolder and WPProgram objects.
ICONFILE     filename        This sets the object's icon.
ICONRESOURCE id,module       This sets the object's icon. 'id' is the
                             identity of an icon resource in the 'module'
                             dynamic link library (DLL). For example:
                             ICONRESOURCE=73 PMWP;
                             This would indicate resource 73 in PMWP.DLL.
                             See a supplied sample command file for more info.
ICONPOS      x,y             This sets the object's initial icon position.
                             The x and y values represent the position in
                             the object's folder in percentage coordinates.
ICONVIEWPOS  w,x,y,z         This sets the object's initial size. The values
                             represent relative position in percentage
                             coordinates. For example: ICONPOS=25 25 50 50
                             Would create a folder whose bottom left corner is
                             25% from the left and 25% from the bottom and half
                             the screen width/height.
TEMPLATE     YES             Creates object as a template.
             NO              Resets objects template property.
TITLE        value           Can be used to assign a name/title to an object.
OBJECTID    
          This sets the object's identity. The object
                             id will stay with the object even if it is
                             moved or renamed. An object id is any unique
                             string preceded with a '<' and terminated
                             with a '>'. This may also be a real name
                             specified as a fully qualified path name.
                             IMPORTANT: For any object you create you should
                             use a unique objectid! Do this for two reasons:
                             1) If you use an objectid it signifies a unique
                                object that will not be recreated if you use
                                the "FailIfExists" flag in your Rexx call. Not
                                using an objectid would cause multiple objects
                                to be created if the same program was run
                                over and over.
                             2) Should you need to later delete it or change
                                your object, you can use this objectid in your
                                Rexx call to refer to it.
                             Also one should not use an objectid that starts
                             with "WP_" as many OS/2 objects use those,
                             consider those reserved characters.
HELPPANEL    id              This sets the object's default help panel.
HELPLIBRARY  filename        This sets the help library.
OPEN         SETTINGS        Open settings view of object when created/updated.
             DEFAULT         Open default view of object when created/updated.
                             Don't forget for folder objects you can use
                             OPEN with these values: ICON, TREE, DETAILS
NODELETE     YES             Will not allow you to delete the object.
             NO              Resets the object's no delete property.
NOCOPY       YES             Will not allow you to make a copy.
             NO              Resets the object's no copy property.
NOMOVE       YES             Will not allow you to move the object to another
                             folder, will create shadow on a move.
             NO              Resets the object's no move property.
NODRAG       YES             Will not allow you to drag the object.
             NO              Resets the object's no drag property.
NOLINK       YES             Will not allow you to create a shadow link.
             NO              Resets the object's no link property.
NOSHADOW     YES             Will not allow you to create a shadow link.
             NO              Resets the object's no shadow property.
NORENAME     YES             Will not allow you to rename the object.
             NO              Resets the object's no rename property.
NOPRINT      YES             Will not allow you to print it.
             NO              Resets the object's no print property.
NOTVISIBLE   YES             Will not display the object.
             NO              Resets the object's not visible property.
-----------------------------------------------------------------------------

****************************
***WPShadow setup string ***
****************************
A shadow object is a persistent link or reference to any other object. This
is achieved by storing away the location and identity of the object that it
is linked to and then rerouting all requests for help, context menus, and
open views on to the object that it is linked to. Delete, Copy, and Move are
the only action requests that are handled by the WPShadow object and are not
rerouted to the linked object.

When you place objects into your Startup folder you should be placing a
shadow object there. See the SHADOW sample code for an example of its usage.

These are the keyname-value pairs supported by the WPShadow class.

KEYNAME      VALUE           Description
-----------------------------------------------------------------------------
SHADOWID    
or       The value for this is an object's id (OBJECTID)
             filename        or a fully qualified pathname of a directory,
                             program file, or data file.
Note: When creating a shadow object always use the OBJECTID= string to give
      your object a unique id so that later you may refer to it, and
      potentially delete it with SysDestroyObject.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
((END TEXT INFORMATION))

 

Здесь приведен текст книги без примеров. Полный текст книги в формате txt можно скачать по этой ссылке.