home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / ppdial31.zip / README.CMD < prev   
OS/2 REXX Batch file  |  1996-12-31  |  1KB  |  31 lines

  1. /* REXX */
  2. address cmd
  3. if RxFuncQuery('SysCreateObject') 
  4.   then call RxFuncAdd 'SysCreateObject', 'RexxUtil', 'SysCreateObject'
  5. if RxFuncQuery('SysOpenObject') 
  6.   then call RxFuncAdd 'SysOpenObject', 'RexxUtil', 'SysOpenObject'
  7.  
  8. /* Try to open the URL object... */
  9. rc = SysOpenObject( '<DNR_PPPDIAL_URL_FILE>', 'DEFAULT', 1 )
  10. if rc = 1 then exit
  11.  
  12. url1 = 'file:///'directory()'\pppdial.htm'
  13. url2 = 'http://www.cam.org/%7etomlins/pppdial.html'
  14.  
  15. /* Try to create a URL WPS object... */
  16. /*    if successful, open it. */
  17. /*    if not successful, start up web explorer instead. */
  18.  
  19. rc = SysCreateObject( 'WPUrl', 'PPPDIAL Documentation (local)', '<URLF_REF>', 'OBJECTID=<DNR_PPPDIAL_URL_FILE>;URL='url1';', 'replace' )
  20. if rc = 0 then do
  21.    'START EXPLORE.EXE pppdial.htm -q -t 8'             
  22. end /* do */
  23. else do
  24.    /* The object was created... open it... */
  25.    rc = SysCreateObject( 'WPUrl', 'PPPDIAL Documentation (on-line)', '<URLF_REF>', 'OBJECTID=<DNR_PPPDIAL_URL_ONLINE>;URL='url2';', 'replace' )
  26.    rc = SysOpenObject( '<DNR_PPPDIAL_URL_FILE>', 'DEFAULT', 1 )
  27.    say 'URL Objects were created in connections\web sites\reference'
  28.    '@pause'
  29. end /* do */
  30.  
  31.