home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 8 Other / 08-Other.zip / nodot.zip / NODOT.CMD next >
OS/2 REXX Batch file  |  1995-03-09  |  3KB  |  64 lines

  1. /**************************************************************************/
  2. /* REXX Procedure to remove the annoying dot from the UK version of       */
  3. /* OS/2 Warp. As I'd suspected earlier, the dot has nothing to do         */
  4. /* with OS2LOGO (which can only be changed via a utility on Devcon 6)     */
  5. /* The annoying dot is in fact in OS2LDR.MSG and consitutes the tail end  */
  6. /* of a copyright message that does not apply in the UK                   */
  7. /* The script edits OS2LDR.MSG at offset 4181 decimal changing            */
  8. /*the dot (2E) to a space (20).. If you want to be smart you can just use */
  9. /*PATCH instead... Enjoy! That dot was driving me nuts!                   */
  10. /* This shouldn't affect anything except the dot, but in any case I am    */
  11. /* not liable, there is no warranty caveat wotsit etc etc                 */
  12. /**************************************************************************/
  13. call RxFuncAdd 'SysLoadFuncs','RexxUtil','SysLoadFuncs'
  14. call SysLoadFuncs
  15. Call SysCls
  16. /* define variable even if you don't need to under REXX */
  17. Continue=0
  18. if SysOS2Ver()<>'2.30' then /* Warp doesnt return as 3.0 !*/
  19. do
  20.     say 'This does not seem to be OS/2 Warp 3.0'
  21.     say 'Are you *sure* you wish to apply this patch? Y/N?'
  22.     parse pull Response
  23.     If Response<>'Y' then exit
  24. end
  25. Say 'Found OS/2 Warp Version 3.0'
  26. LocalDrives=SysDriveMap(,LOCAL)
  27. FoundOS2LDR=0
  28. DO LoopCounter=1 to WORDS(LocalDrives)
  29. NextLDR=WORD(LocalDrives,LoopCounter)'\OS2LDR.MSG'
  30. rc=SysFileTree(NextLDR,'Results','F','*****','**---')
  31.  if Results.0=1 then
  32.     DO
  33.       FoundOS2LDR=LoopCounter
  34.       LoopCounter=WORDS(LocalDrives)
  35.     END
  36. end
  37. if FoundOS2LDR=0 then
  38. DO
  39.    SAY "I couldn't find OS2LDR.MSG for some strange reason"
  40.    SAY  'no idea what to do. quitting'
  41.     EXIT
  42. END
  43. else
  44.     SAY 'OS2LDR.MSG found on Drive' WORD(LocalDrives,FoundOS2LDR)
  45.     SAY 'Read Only, System and Hidden attributes removed'
  46. rc= CHAROUT(NextLDR,' ',4181)
  47. if rc=0 then
  48. DO
  49. say 'Dot Exterminated'
  50. Src=CHAROUT(NextLDR)
  51. rc=SysFileTree(NextLDR,'Results','F','*****','+*+++')
  52. say 'Read Only, Hidden & System attributes restored for OS2LDR.MSG'
  53. say 'Reboot to see no dot :-)'
  54. say ''
  55. Say 'Compliments of:'
  56. say ''
  57. say '..Peter Kay, OS/2 Programmer, OS/2 Power Editor...........'
  58. say '. e-mail: P.J.KAY@ITI.SALFORD.AC.UK                      .'
  59. say '..........................................................'
  60. END
  61. else
  62. say 'Unknown error - try running this program again'
  63.  
  64.