home *** CD-ROM | disk | FTP | other *** search
/ Chip 1998 March / Chip_1998-03_cd.bin / tema / imagin / Files / acxunins.bat < prev    next >
DOS Batch File  |  1998-01-20  |  2KB  |  74 lines

  1. @echo  off
  2. rem Un-install ActiveCGM control script
  3. rem InterCAP Graphics Systems
  4. rem Sep 15, 1997
  5. rem
  6. rem Check  to  see  if  acgm.ocx exists
  7.  
  8. set afile=%windir%\system32\acgm.ocx
  9. if  exist  %afile%  goto  fileexists
  10.  
  11. set afile=%windir%\system\acgm.ocx
  12. if  exist  %afile%  goto  fileexists
  13.  
  14. set afile=%windir%\occache\acgm.ocx
  15. if  exist  %afile%  goto  fileexists
  16.  
  17. set afile=\windows\system\acgm.ocx
  18. if  exist  %afile%  goto  fileexists
  19.  
  20. set afile=\winnt\system32\acgm.ocx
  21. if  exist  %afile%  goto  fileexists
  22.  
  23. set afile=\windows\occache\acgm.ocx
  24. if  exist  %afile%  goto  fileexists
  25.  
  26. set afile=\winnt\occache\acgm.ocx
  27. if  exist  %afile%  goto  fileexists
  28.  
  29. goto  nofile
  30.  
  31. :fileexists
  32. echo  The  file  %afile%  exists
  33. rem
  34. rem Check for regsvr32
  35. if exist %windir%\system32\regsvr32.exe goto runcmd0
  36. if exist %windir%\system\regsvr32.exe goto runcmd1
  37. if exist \winnt\system32\regsvr32.exe goto runcmd2
  38. if exist \windows\system\regsvr32.exe goto runcmd3
  39. goto norun
  40.  
  41. :runcmd0
  42. %windir%\system32\regsvr32.exe /u %afile%
  43. if errorlevel 0  del %afile%
  44. goto end
  45.  
  46.  
  47. :runcmd1
  48. %windir%\system\regsvr32.exe /u %afile%
  49. if errorlevel 0  del %afile%
  50. goto end
  51.  
  52.  
  53. :runcmd2
  54. \winnt\system32\regsvr32.exe /u %afile%
  55. if errorlevel 0  del %afile%
  56. goto end
  57.  
  58. :runcmd3
  59. \windows\system\regsvr32.exe /u %afile%
  60. if errorlevel 0  del %afile%
  61. goto end
  62.  
  63. :norun
  64. echo Cannot find regsvr32.exe 
  65. echo Please execute regsvr32.exe /u %afile%
  66. goto end
  67.  
  68.  
  69.  
  70. :nofile
  71. echo  acgm.ocx does not exist - probably this is the first install
  72. goto  end
  73.  
  74. :end