REXX Tips & Tricks:Non-REXX related information
This section contains some additional information that is not REXX related but nevertheless useful - at least for me 'cause I'm using REXX mostly for CID installations and upgrades :-).
Environment variables & system variables
This section contains information about environment variables and CONFIG.SYS statements used by OS/2 and other programs.
The information in this section is collected from various sources.
For further information about the CONIFG.SYS I strongly recommend the tool ConfigTool.
Note: The CONFIG.SYS used if using ALT-F1 while the white square box is visible and than "C" to boot to a command shell is the file \OS2\BOOT\config.x .
Simulating an AUTOEXEC.BAT for OS/2 sessions
To simulate an AUTOEXEC.BAT for OS/2 sessions you can change the \CONFIG.SYS statement for OS2_SHELL to something like
SET OS2_SHELL=C:\OS2\CMD.EXE /K C:\AUTOEXEC.CMD
In this example the program AUTOEXEC.CMD is executed for every new OS/2 session. (see also Special filenames)
You may use this feature to set LIBPATHSTRICT in every OS/2 session ( CONFIG.SYS statements used by OS/2)
Source: The OS/2 WARP Survival Guide
Hints for programs and driver loaded in CONFIG.SYS
This section contains hints for programs and driver loaded in the CONFIG.SYS .
==Loading HPFS.IFS (WARP 4)==
Use the undocumented switch /FORCE for this filesystem to force immediate access to a "dirty" HPFS partition. HPFS partitions get "dirty" if you don't shutdown OS/2 (e.g. after crashing the system).
Use the undocumented switch /QUIET for this filesystem to suppress all messages from CHKDSK. Note that /QUIET cannot be the last parameter.
Example:
IFS=C:\OS2\BOOT\HPFS.IFS /FORCE /AUTOCHECK:C
Warning: Use these parameters with extreme care! Use it only when you really need it!
- WARP 4 only!, Source: Team OS/2 WEB pages)
==Loading IBMKBD.SYS (WARP 4)==
The driver IBMKBD.SYS in WARP 4 accepts the parameters /NUMON and /NUMOFF to turn NUMLOCK on or off. These parameters used to work in the MERLIN Beta, but they are disabled in the WARP 4 GA.
CONFIG.SYS statements used by OS/2
This section contains some information about undocumented or poorly documented CONFIG.SYS statements used by OS/2.
AUTOFAIL=x x maybe yes (no popup message for harderrors) or no (popup message for harderrors), default is no. Note that the DLL RXU contains a function to dynamically switch popup windows on and off.
Available: All versions Source: various
AUTOREFRESHFOLDERS=NO Suppress the automatic refresh of folder contents. If this feature is activated, you must manually refresh the view of a folder after each action
Available: WARP 4 only! Source: various
DLLBASING=OFF Reduce the fragmentation of loaded DLLs (ON by default)
Available: WSeB or after applying FP13 to Warp4 Source: various
DUMPPROCESS=x Activate the dump process. The dump goes to the file PDUMP.nnn in the root directory of drive specified in x (where nnn is an unique number).
Available: All versions Source: various
EARLYMEMINIT=TRUE Adding "EARLYMEMINIT=TRUE" to config.sys will allow device drivers, etc., access to the memory above 16mb early in boot. Previously, this was only available after DD and IFS init was completed. This has various implications when enabled:
large VDISKs are possible. I tried DEVICE=\os2\vdisk.sys 16000 AHA154X.ADD may do bad things to your system. Don't even ask. There may be some settings of HPFS386 cache that are incompatible. This feature is experimental. Available: only available in the WARP kernels from testcase Source: various
I13PAGES=1 SMP kernels could not be RIPL-booted. As part of this, there is a new config.sys parameter I13PAGES= available. Adding I13PAGES=1 to config.sys (note, no SET) reduces the memory usage of the mini VDM processes used by ibm1s506.add and the GRADD drivers. This becomes important in RIPL-boot situations.
Available: only available with Kernel 14.062 or higher Source: various
MENUSTYLE=SHORT Disable some entries from the object context menus
Available: All versions Source: various
OBJECTSNOOZETIME=n n is the snooze time for objects and DLLs in seconds (default is 90) (see Note)
Available: All versions Source: various
PAUSEONERROR=x Pause after each error in the CONFIG.SYS (x=YES) or not (x=NO). Default is YES.
Available: All versions Source: various
REIPL=x Save trap information into a file and reboot the workstation (x=ON) or display an error message (x=OFF). Default is OFF.
Available: All versions Source: various
RESERVEDRIVELETTER=x "The ability to reserve drive letters feature has been added at WARP FixPak level XRUW024. A modification has been made to the OS/2 kernel that will allow the user to specify, through a CONFIG.SYS parameter, specific drive letters that will not be allocated for local block mode devices during the processing of CONFIG.SYS.
SYNTAX: RESERVEDRIVELETTER=x
where x is letter D thru Z. Multiple RESERVEDRIVELETTER statements is be allowed."
Available: WARP 3 FixPack #24 and newer (e.g. Warp4, WSeB,etc) Source: various
SHAPIEXCEPTIONHANDLER=OFF Disable the WPS API exception handler (see Note)
Available: All versions Source: various
SHELLEXCEPTIONHANDLER=OFF Disable the WPS exception handler (see Note)
Available: All versions Source: various
SET DEVICEFONTDISABLED=NO Setting this to YES. will cause very large/slow print jobs, since no uploaded/internal printer fonts will be used. You want it set to NO in most cases (NO is the default).
Available: WSeB and probably more recent WARP 3/4 fixpaks Source: Peter Fitzsimmons (see EMail Addresses)
SET ENH_STRETCH=NO The new feature "enhanced stretch-blitting" has one known ill side-effect, where some of the icons for folders and other items will appear "washed out" when running in 24bpp or 32bpp. To fix this, you can disable the new feature by adding this line.
Available: Warp 4 FP14 and newer (e.g. Warp4, WSeB,etc) Source: ConfigTool
SET KILLFEATUREENABLED=on Activate the list of all processes in the WarpCenter (hold down CTRL and click on the windows icon on the WarpCenter to open the list). Note that you can also use SCKILLFEATUREENABLED.
Available: WARP 4 only! Source: c't 1/1997
SET LIBPATHSTRICT=x (x maybe T (true) or F (false) Allows creation of a local version of the BEGINLIBPATH statement that can include DLLs that have the same name as globally loaded DLLs. The local DLLs are checked before the globals. Thus if your program has a DLL that is the same name as another, you can create a command file with the SET LIBPATHSTRICT=T, a SET BEGINLIBPATH=my program's dll, and the path & name of my program, and run your program.
Note that you must set this environment variable in an OS/2 session - an entry like "SET LIBPATHSTRICT=T" in the CONFIG.SYS is useless. (see also Simulating an AUTOEXEC.BAT for OS/2 sessions)
Available: New kernel instruction in WARP kernels from testcase since September 1, 2000 Source: ConfigTool
SET MENUSFOLLOWPOINTER=ON This makes the WarpCenter menus behave like the Start menu of Windows 95: The menus follow the mouse pointer.
Available: WARP 4 with Fixpack #5 or later Source: various
SET NOLARGENTEXEICON=n Limit the number of megabytes (=n) the WPS should scan through Windows EXE files for the program icon before assigning a default icon
Available: New kernels from testcase (APAR PJ27886) Source: XWorkplace Mailinglist
SET NEWNOTEBOOKS=ON Enables the new notebooks for applications written prior to WARP 4
Available: This setting worked in the MERLIN Beta, but seems to be disabled in WARP 4 GA. Source: various
SET PM_ASYNC_FOCUS_CHANGE=x {time} Enable the SIQFix (Single Input Queue Fix) and set the custom time-out to time ms (default: 2000). Set x to OFF or remove the statement to disable the SIQFix
Available: WARP 3 FixPack #17 and newer (e.g. Warp4, WSeB,etc) Source: various
SET PM_DYNAMIC_DRAG=x Activate (x=ON) or deactivate (x=OFF, default) the full window drag for PM windows
Available: WARP 3 FixPack #17 and newer (e.g. Warp4, WSeB,etc) Source: various
SET PM_ROLLUP_BUTTON=YES Adds a new button to the window titlebars that you can use to "Roll up your PM windows to just a titlebar".
Available: This setting worked in the MERLIN Beta, but seems to be disabled in WARP 4 GA. Source: Team OS/2 WEB pages
SET PM_PRINTSCREEN_ACTIVE_WINDOW=x (x can be ON or OFF) If x is ON the window with the focus will print when a Print Screen operation is initiated. If x is OFF, the default Print Screen operation takes place.
Available: Warp 4 FP13 Source: ConfigTool
SET QUEUE_SIZE_THRESHOLD=X Change the size of the message queue. Default is 100 for version prior to the WARP 3 Fixpack #17 and 3000 for the WARP 3 Fixpack #17.
Available: WARP 3 FixPack #17 and newer (e.g. Warp4, WSeB,etc) Source: various
SET RESTARTOBJECTS=x Control the restart behaviour of the WPS, x may be YES (default), NO, STARTUPFOLDERSONLY or REBOOTONLY.
Available: All versions Source: various
SET RUNWORKPLACE=C:\OS2\PMSHELL.EXE This statements points to the shell program to use - normally that's the program C:\OS2\PMSHELL.EXE. But you can change this to any other program if you want to restrict the PC to only run that program (e.g. SET RUNWORKPLACE=C:\OS2\MDOS\WINOS\PROGMAN.EXE).
Available: All versions Source: various
SET SCCANBENUKED=ON This makes the WARPCenter object "nukeable" i.e. you can right click and choose "Delete" which is not possible normally. If SCCANBENUKED does not work, try CANBENUKED.
Available: WARP 4 only! Source: Team OS/2 WEB pages
SET SCFINDUTILITY={anyprogram_or_anyObjectID} This allows you to define any external program (OS/2, DOS, Windows, or even an object ID like <WP_OS2SYS>!) for the flashlight icon on the WARPCenter. Click the little flashlight icon (WARPCenter) and you get whatever you specified. If SCFINDUTILITY does not work, try FINDUTILITY.
Available: WARP 4 only! Source: Team OS/2 WEB pages
SET SCKILLCONFIRMDISABLED=ON Avoid the "Are you sure dialog" if using the kill feature of the WARPCenter activated with SET KILLFEATUREENABLED=on. Note that you must also add the entry SET KILLCONFIRMDISABLED=1 to make this work.
Available: WARP 4 only! Source: Team OS/2 WEB pages
SET SCUSEPRETTYCLOCK=1 Change the color of the clock from the WARPCenter to green on black If SCUSEPRETTYCLOCK does not work, try USEPRETTYCLOCK.
Available: WARP 4 only! Source: Team OS/2 WEB pages
SET SHELLHANDLESINC=n Increment the number of file handles available to a shell process (e.g. a REXX program started by the CMD.EXE) by the amount of n. (see also Maximum files per session; tested only in WARP 4 with Fixpack #6)
Available: WARP 4 with Fixpack #6 Source: various
SUPPRESSPOPUPS=x Save error information into the file POPUPLOG.OS2 in the root directory of the drive x and suppress the dialogs (On WARP 4 with Fixpack #3 x may be 0 to simulate the behaviour of OS/2 versions prior to this version).
Available: All versions Source: various
SXFAKEHWFPU=1 Activate a fix for a "math rounding error" in WARP 4
Available: WARP 4 only! Fixpack #1 Source: WARP 4 Fixpack 1 documentation
VIRTUALADRESSLIMIT=n (n is the limit in kb)
The default value for VIRTUALADDRESSLIMIT in OS/2 Warp Server for e-business is 1 GB (n=1024). The VIRTUALADDRESSLIMIT parameter is also available for OS/2 Warp Server SMP Feature and Warp 4.0 Fixpak 13. Areas of memory below 512 MB have been remapped for higher availability in that region.
2048 allows max. memory allocated 2 Gigs of shared RAM. Only useful for developers.
You must have a hard disk that can accommodate the swap file. UW2SCSIs are recommended for the swap disk unless you wish to see your computer behave like a washing machine in spin dry mode.
The OS/2 Warp Server Advanced SMP addendum states that this number can go to 3 Gigs. Memory support has also been enhanced since now an application can access a virtual memory address space of up to 3 GB by use of the VIRTUALADDRESSLIMIT = 3072 parameter in CONFIG.SYS. Areas of memory below 512 MB have been remapped for higher availability in that region.
Available: WSeB, Warp Server SMP, and Warp 4.0 Fixpak 13 Source: ConfigTool
VME=NO Turn "Virtual mode extension (VME)" off (see Note about VME)
Available: All versions Source: various
Note about VME
"Virtual Mode Extensions is a hardware enhancement Intel added to their CPUs beginning with the DX2 models. All Pentium processors also come with this feature. VME is intended to speed up a number of privileged functions (CPU instructions) for applications running in virtual mode sessions (for example, DOS and WinOS2 sessions).
DOS (and Windows) apps running in an OS/2 Virtual DOS Machine (VDM) believe they "own" the hardware. On occasion these apps will try to do something to the (virtual) hardware that isn't permitted while a protected mode operating system such as OS/2 is in control of the real hardware because permitting such "privileged" operations would negatively impact overall system integrity and reliability.
On a non-VME processor attempting such privileged operations would result in a (hardware generated) program interrupt, and hence an operating system (in this case, OS/2) interrupt handler to get control. Control would eventually pass to a routine that would simulate the attempted function. On a VME processor the function simulation would be carried out by microcode on the processor itself. This is both transparent (to the operating system and app) and faster, BUT only if it works<g>.
Unfortunately there are apparently some conditions that can arise where this (usually) transparent handling of privileged operations (in effect, a hardware implemented microcode "assist") can leave the system in an inconsistent operating state. In this case the operating system will force a TRAP condition to protect itself (and YOUR data).
Adding the "VME=NO" line to "CONFIG.SYS" forces all VME "assisted" CPU instructions to be reflected to, and handled by, the operating system; in other words, the way it would have worked had the VME feature not have been present.
"VME=NO" is not a panacea fix for all your DOS/Windows woes. Indeed the most common symptom of VME related problems is frequent "Trap D" and "Trap E" errors in DOS and WinOS2 sessions. Therefore, I doubt it will correct all the problems you've listed, but it MAY provide some relief. Can't hurt to try.
Ron Higgin OS/2 Advisor! (see EMail Addresses)"
Environment variables used by OS/2
This section contains some information about undocumented or poorly documented environment variables used by OS/2.
Please note, that you must use SET name=value to use the environment variables!
CONNECT_DASD=NO Turns off DASD checking while installing OS/2. This enables the user to install a product if the installation program thinks there is not enough diskspace (used by the OS/2 WARP Connect installation program)
Available: All versions Source: various
CONNECT_PREREQ=NO Turns off prerequisite checking. This enables the user to install a product when the installation program thinks that it cannot be installed (used by the OS/2 WARP Connect installation program).
Available: All versions Source: various
CONNECT_SNIFF=NO Turns off network card detection. This may be necessary if the detection logic hangs the machine while detecting adapters (used by the OS/2 WARP Connect installation program).
Available: All versions Source: various
COPYFROMFLOPPY=1 Set to 1, if the OS/2 installation program should copy drivers from disk A: instead of copying this files from the CD-ROM
Available: All versions Source: various
DELDIR=path_for_the_deleted_files This is a real environment variable, see DELDIR
Available: All versions Source: various
DESKTOP=wps_directory|wps_object_ID Points to the WPS directory if the object ID <WP_DESKTOP> is missing in the ini file
Available: All versions Source: various
DIRCMD=default_dir_switches Used to set the default options for the DIR command DOSSETTING.{dossetting}={value} Use the value {value} for the setup string {dossetting} in the next DOS session opended with the �START command. (see Start a program with specific settings for an example; WARP 4 only!).
Available: All versions Source: various
SOURCEPATH=os2_image_directory Points to the disk images used by the OS/2 installation program SYSINST2.EXE
Available: All versions Source: various
SYSTEM_INI=C:\OS2\OS2SYS.INI This statement contains the path & name of the system ini file.
Available: All versions Source: various
TRUEMODE=1 Set this environment variable to install the TrapDoor feature of WARP 4, even on a machine with SCSI HDs only.
Available: WARP 4 only! Source: various
USER_INI=C:\OS2\OS2.INI This statement contains the path & name of the user ini file.
Available: All versions Source: various
VIDEO_DEVICES=env_var This statement sets the name of the OS/2 environment variable that contains the base video driver name.
Available: All versions Source: The OS/2 WARP Survival Guide
VIO_SVGA=DEVICE(BVHVGA,BVHSVGA) This statement selects the base video support.
Available: All versions Source: The OS/2 WARP Survival Guide
WIN3DIR=win311_directory This environment variable must point to the directory with your Windows 3.1 if using the TrapDoor feature of WARP 4.
Available: WARP 4 only! Source: various
WP_OBJHANDLE=n This environment variable contains the object handle for the current OS/2 session. This handle is unique for each OS/2 session started via an WPS Object. Note that OS/2 sessions started via the �START command inherit the value from the parent.
Available: All versions Source: various
DELDIR
You can change the environment variable �DELDIR in OS/2 sessions to change the �UNDELETE behaviour for a special session.
Examples:
REM *** OS/2 Batch file to change the DELDIR directory for one session SET DELDIR=C:\DELDIR1,512;D:\DELDIR_C,512;
REM *** OS/2 Batch to disable DELDIR, delete some files and enable REM DELDIR again
SETLOCAL SET DELDIR= DEL D:\TEMP\*.* ENDLOCAL
REM *** OS/2 Batch to change the DELDIR directory, delete some files REM and restore the DELDIR directory afterwards SETLOCAL SET DELDIR=D:\MY_DELDIR,512 DEL D:\TEMP\*.* ENDLOCAL
Note: This method is also possible in DOS sessions.
Environment variables used by other OS/2 programs
This section contains some information about undocumented or poorly documented environment variables used by other OS/2 programs.
CSFCDROMDIR=path Points to the directory with the fixpack (used by SERVICE.EXE) CSFUTILPATH=path Points to the directory with the files from the kicker diskettes (used by SERVICE.EXE) EPFINSTDIR=path Points to the configuration files for the Software Installer/2 (default is \OS2) IBMWORKS_INI=path Points to the path for data files for the PIM from IBM Works IROPT=options Undocumented environment variable for Dualstor (IBM) possible values: d: no FIFO, D: use FIFO, x: 0.5 MBit/s, X: 1 MBit/s NCDEBUG=n Environment variable needed by Lotus 123 for video and audio playback REMOTE_INSTALL_STATE=x Environment variable used for CID installations. Warning: If this variable is defined, all installation programs created with Software Installer/2 will not display!
BEGINLIBPATH/ENDLIBPATH
You cannot use the "environment variables" BEGINLIBPATH and ENDLIBPATH (OS/2 Version 3.0 and above) in a REXX program because these are not real environment variables. Statements like
say " BeginLibPath=<" || value( "BEGINLIBPATH " ,, "OS2ENVIRONMENT") || ">" say " EndLibPath=<" || value( "ENDLIBPATH " ,, "OS2ENVIRONMENT") || ">"
will always return
BeginLibPath=<> EndLibPath=<>
To set the "variable" BEGINLIBPATH in a REXX program you must use the OS/2 command SET:
"SET BEGINLIBPATH=C:\MYLIBS"
If you try to modify BEGINLIBPATH/ENDLIBPATH with the �SET command AND with the REXX function �VALUE at the same time, OS/2 produces a strange result:
It creates two variables, both named BEGINLIBPATH (The correct variable is the variable with the blanks before and after the equal sign.). The environment variable BEGINLIBPATH set with the REXX function �VALUE is only accessible with %BEGINLIBPATH% - the REXX function �VALUE can not read the environment variable. To equalize this the CMD.EXE can't read the "variable" set with the SET command anymore if there's an environment variable set with the REXX function VALUE.
By the way: If you want to use the value of the "variable" BEGINLIBPATH set with the SET command in other OS/2 commands with %BEGINLIBPATH% you must write the name complete in uppercase. But, of course, there's also an exception to this rule: If you want to change the variable BEGINLIBPATH with a command like SET BEGINLIBPATH=%BEGINLIBPATH%;C:\newPart you can write BEGINLIBPATH in lowercase or mixed case also.
Additional note: The CMD.EXE does some validation for the value for BEGINLIBPATH - a value for this variable is only accepted if all parts of the value (separated with a semicolon ;) contain at least one : or \. An invalid part of the value and all parts behind the invalid part are ignored. And last: the maximum length for BEGINLIBPATH is 1024 characters.
Before I forget: The described behavior is also true for ENDLIBPATH -- at least one rule without an exception.
Last note: BEGINLIBPATH and ENDLIBPATH are not supported by 4OS2 until version 2.5a. JP Software recommends to use aliase like
BEGINLIBPATH=d:\path\cmd /c beginlibpath ENDLIBPATH=d:\path\cmd /c endlibpath
if you really want to use them in 4OS2 version 2.5a. In 4OS/2 version 2.51b, JP Software has fixed the problems that 4OS/2 was having with BEGINLIBPATH/ENDLIBPATH..
see also Detecting the LIBPATH values
Detecting the LIBPATH values
/* sample REXX routine to get the values of LIBPATH, BEGINLIBPATH */ /* and ENDLIBPATH */ /* */ /* RXT'T v3.20: Changed code to get BEGINLIBPATH and ENDLIBPATH */ /* new code tested with WARP 4 US Fixpack #15 */ /* */ say "Detecting the values of LIBPATH, BEGINLIBPATH and ENDLIBPATH ..." BootDrive = "C:" thisRC = GetLibPath( bootDrive ) select when thisRC = 0 then do say " LIBPATH = " || LIBPATH say " BEGINLIBPATH = " || BEGINLIBPATH say " ENDLIBPATH = " || ENDLIBPATH end /* when */ when thisRC = 2 then do say " LIBPATH = " say " -> File " || BootDrive || "\CONFIG.SYS not found!" say " BEGINLIBPATH = " || BEGINLIBPATH say " ENDLIBPATH = " || ENDLIBPATH end /* when */ otherwise do say "Unexpected return code " || thisRC || "!" end /* otherwise */ end /* select */ exit /* ------------------------------------------------------------------ */ /* function: Get the value for LIBPATH, BEGINLIBPATH and ENDLIBPATH */ /* */ /* Usage: GetLibPath bootDrive */ /* */ /* where: bootDrive - boot drive (e.g. "C:") */ /* */ /* returns: 0 - ok */ /* 2 - config.sys not found */ /* -1 - parameter missing */ /* -2 - error reading the CONFIG.SYS v3.20 */ /* */ /* output: LIBPATH - value of LIBPATH entry or empty string */ /* BEGINLIBPATH - value of BEGINLIBPATH or empty string */ /* ENDLIBPATH - value of ENDLIBPATH or empty string */ /* */ GetLibPath: PROCEDURE expose LIBPATH BEGINLIBPATH ENDLIBPATH parse arg bootDrive . /* init the return code */ thisRC = 0 LIBPATH = '' /* v3.20 */ BEGINLIBPATH = '' /* v3.20 */ ENDLIBPATH = '' /* v3.20 */ /* check the parameter */ if bootDrive <> "" then do /* get the LIBPATH value */ configSys = left( bootDrive,1 ) || ":\CONFIG.SYS" lineSeparator = "0D0A"x libpathStmt = lineSeparator || "LIBPATH=" if stream( configSys, "c", "QUERY EXISTS" ) <> "" then do configSysLength = chars( configSys ) /* v3.20 */ if stream( configSys, "c", "OPEN READ" ) = 'READY:' then do configSYS = CharIn( configSys, 1, configSysLength ) call stream configSys, "c", "CLOSE" parse upper var ConfigSYS . (libPathStmt) LIBPATH (lineSeparator) . LIBPATH = strip( LIBPATH ) end /* if */ else do /* v3.20 */ /* error opening the CONFIG.SYS */ thisRC = -2 end /* else */ end else thisRC = -1 /* get BEGINLIBPATH and ENDLIBPATH */ call GetDynamicLibPath end /* if bootDrive <> "" then */ else thisRC = -1 RETURN thisRC /* ------------------------------------------------------------------ */ /* function: Get the value for BEGINLIBPATH and ENDLIBPATH */ /* */ /* Usage: GetDynamicLibPath */ /* */ /* where: - */ /* */ /* returns: - */ /* */ /* output: */ /* BEGINLIBPATH - value of BEGINLIBPATH or empty string */ /* ENDLIBPATH - value of ENDLIBPATH or empty string */ /* */ GetDynamicLibPath: PROCEDURE expose BEGINLIBPATH ENDLIBPATH /* */ /* save the OS/2 environment */ '@SETLOCAL' /* copy the value of BEGINLIBPATH and ENDLIBPATH */ /* into "normal" environment variables */ '@SET val1=%BEGINLIBPATH%' '@SET val2=%ENDLIBPATH%' /* retrieve the "normal" env variables */ beginlibpath = value( 'val1',, 'OS2ENVIRONMENT' ) endlibpath = value( 'val2',, 'OS2ENVIRONMENT' ) /* restore the OS/2 environment */ '@ENDLOCAL' return '' /* ------------------------------------------------------------------ */ /* function: Get the value for BEGINLIBPATH and ENDLIBPATH */ /* */ /* Usage: GetDynamicLibPath */ /* */ /* where: - */ /* */ /* returns: - */ /* */ /* output: */ /* BEGINLIBPATH - value of BEGINLIBPATH or empty string */ /* ENDLIBPATH - value of ENDLIBPATH or empty string */ /* */ /* notes: Use this method if the routine above does not work. */ /* */ /* */ Old_GetDynamicLibPath: PROCEDURE expose BEGINLIBPATH ENDLIBPATH /* get the value of BEGINLIBPATH and ENDLIBPATH */ '@SET BEGINLIBPATH 2>NUL | rxqueue' '@SET ENDLIBPATH 2>NUL | rxqueue' if queued() <> 0 then do parse pull BEGINLIBPATH if BEGINLIBPATH = "(null)" then BEGINLIBPATH = "" end /* if queued() <> 0 then */ else BEGINLIBPATH = "" if queued() <> 0 then do parse pull ENDLIBPATH if ENDLIBPATH = "(null)" then ENDLIBPATH = "" end /* if queued() <> 0 then */ else ENDLIBPATH = "" return ''