home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
netdor3.zip
/
VNDINST
/
FRNTENDS
/
MSWORD
/
PACKRUN.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1996-04-04
|
2KB
|
70 lines
/******************************************************************
Description: MSWORD Run Exec.
Details: This exec changes to the appropriate local MSWORD
directory, modifies the current PATH and DPATH
appropriately, and then runs MSWORD.
Dependencies:
Externals: RXUTILS.DLL - Part of VENDOR package.
Drive(s): None
Directories: None
Window Type: FS/Win
App Title: None
Last Updated: 4/2/91
******************************************************************/
trace 'O'
'@echo off'
/** Setup needed variables **/
call RxFuncAdd 'RXGREP', 'RXUTILS', 'RXGREP'
call RxFuncAdd 'RXPAUSE', 'RXUTILS', 'RXPAUSE'
call RxFuncAdd 'RXMKDIR', 'RXUTILS', 'RXMKDIR'
Env='OS2ENVIRONMENT' /* Set the REXX environment var */
oldpath=value('PATH', , Env) /* Get current path */
olddpath=value('DPATH', , Env) /* Get current dpath */
parse upper source . . exec /* Get packrun filespec */
LanDrv=left(exec,3) /* Get lan drive */
/** Give the header **/
say; say
say 'MSWORD'
say '------'; say
/** Make sure we can find the personal subdirectory **/
pdir=value('MSWNET',,Env) /* Get personal word dir if exists */
if pdir='' then do /* If not, scan CONFIG.SYS for it */
if RxGrep('SET MSWNET=', 'C:\CONFIG.SYS', 'grep')=0 then
if grep.0>0 then do
pdir=space(substr(grep.1, pos('=', grep.1)+1))
call value 'MSWNET', pdir, Env
end
end
/** Run the program if the personal directory was found */
if pdir='' then do
say d2c(7)
say 'Could not determine your MSWORD personal directory.'
say
say 'Please make sure you have run the installation program'
say 'for MSWORD.'; say
call RxPause
end
else do
call value 'PATH', LanDrv';'oldpath, Env
call value 'DPATH', LanDrv';'olddpath, Env
call RxMkDir pdir
call directory pdir
say 'Personal directory is 'pdir'.'
say
say 'Microsoft Word is loading, please wait...'
LanDrv'WORD'
end
'exit'