home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / os / os2 / misc / 30082 < prev    next >
Encoding:
Internet Message Format  |  1992-09-14  |  2.1 KB

  1. Path: sparky!uunet!haven.umd.edu!darwin.sura.net!spool.mu.edu!sol.ctr.columbia.edu!destroyer!ubc-cs!bcsystems!bcsc02.gov.bc.ca!CFORDE
  2. Newsgroups: comp.os.os2.misc
  3. Subject: Re: Lost all system objects, not all apps
  4. Message-ID: <16862E1E3.CFORDE@bcsc02.gov.bc.ca>
  5. From: CFORDE@bcsc02.gov.bc.ca
  6. Date: Mon, 14 Sep 92 16:03:31 PDT
  7. References: <BALDWIN.92Sep14173711@csservera.scs.usna.navy.mil>
  8. Organization: BC Systems Corporation
  9. Nntp-Posting-Host: bcsc02.gov.bc.ca
  10. Lines: 41
  11.  
  12. In article <BALDWIN.92Sep14173711@csservera.scs.usna.navy.mil>
  13. baldwin@csservera.scs.usna.navy.mil (J.D. Baldwin) writes:
  14.  
  15. >
  16. >How can I a) get this stuff back, or b) failing that, re-install the originals
  17. >from the install disks without re-installing all of OS/2?
  18. >
  19. Maybe the following utility will help:
  20.  
  21. /* ReCreate.CMD - restore lost desktop objects */
  22. /* by Greg Czaja - July 29, 1992               */
  23. /* requires July's REXX20 fixes                */
  24.  Call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  25.  Call SysLoadFuncs;
  26.  SysBootDrive=Filespec('Drive',Value('COMSPEC',,'OS2ENVIRONMENT'));
  27.  file_name=SysBootDrive||'\OS2\INI.RC';
  28.  Say "The program will list all standard WPS objects"
  29.  Say "Reply Yes if you want recreate given object"
  30.  Say "Default reply is No if you press ENTER,"
  31.  Say "Enter End if you want to end the program:"
  32.   Do While Lines(file_name) > 0;
  33.      line=Linein(file_name);
  34.      If line='' Then Iterate;        /* skip blanks   */
  35.                    /* get the "create object lines    */
  36.      Parse Var line '"PM_InstallObject"' line;
  37.      If line='' Then Iterate;        /* skip others   */
  38.      Parse Var line '"'head'" 'line; /* get header    */
  39.      Parse Var line '"'setup'"' .;   /* get setup string */
  40.      Parse Var head title';'object';'location;
  41.      Say title "- Yes/No/End ?";
  42.      Pull reply ;
  43.      If Left(reply,1) = 'E' Then Leave;
  44.      If Left(reply,1) <> 'Y' Then Iterate;
  45.      If SysCreateObject(object,title,location,setup,'Replace') = 0
  46.         Then Say 'Error creating:' title;
  47.         Else Say title 'created !';
  48.   End;
  49.  rc=Stream(file_name,'C','Close');
  50. Exit;   /* Enjoy your desktop ! */
  51.  
  52.  
  53.