home *** CD-ROM | disk | FTP | other *** search
/ PC World 2004 September / PCWorld_2004-09_cd.bin / hardware / nvidia / xp / 61.77_win2kxp_international.exe / NVDisp.nvu < prev    next >
Encoding:
Text File  |  2004-07-15  |  13.2 KB  |  384 lines

  1. ; NVIDIA Display Driver uninstaller
  2. call Uninstall
  3.  
  4. [UninstallSilent]
  5. Set ForceNoReboot=yes
  6. Set Silent=yes
  7. call Uninstall
  8. Delreg {UninstRegkey}\NVIDIA Display Driver
  9. del {current Script}
  10. del {Current Parser Path}
  11.  
  12. [Uninstall]
  13. ; Unregister any DLLs
  14. SysCallAndWait {sysdir}\regsvr32.exe /s /u {sysdir}\nvcpl.dll
  15. SysCallAndWait {sysdir}\regsvr32.exe /s /u {sysdir}\nview.dll
  16. SysCallAndWait {sysdir}\regsvr32.exe /s /u {sysdir}\nvshell.dll
  17. SysCallAndWait {sysdir}\regsvr32.exe /s /u {sysdir}\nvwdmcpl.dll
  18.  
  19. UninstallService NVSvc
  20.  
  21. set nViewDialogRegkeyPath=Software\NVIDIA Corporation\Global\nViewInstalled
  22. if {Silent}=yes then delreg HKLM\{nViewDialogRegkeyPath}
  23. if {Silent}=yes then delreg HKCU\{nViewDialogRegkeyPath}
  24.  
  25. SysCallAndWait {sysdir}\nwiz.exe /uninstall
  26. ; remove nView dir if empty
  27. Del {windir}\nView 
  28.  
  29. call Clean up registry
  30.  
  31. ; Get rid of the non-workstation NV specific stuff in the local area
  32. set Current Root Key=HKCU
  33. set Current Reg Key=\Software\NVIDIA Corporation
  34. call DelNoneWorkStationKeys
  35. set Current Root Key=HKLM
  36. call DelNoneWorkStationKeys
  37. EnumRegCmd HKU\\{*}\Software\NVIDIA Corporation,Call DelNoneWorkStationKeys
  38.  
  39. delreg HKCR\TypeLib\{1AFBF72B-58EA-41CB-B117-3CDE0857F4A6}
  40.  
  41. Call DeleteFiles
  42.  
  43. RemoveDevice pci,VEN_10DE,Display
  44.  
  45. DelReg HKLM\Software\Microsoft\Windows\CurrentVersion\Run\NvDeskMgrRestart
  46.  
  47. enumregcmd HKLM\SYSTEM\{*ControlSet}\Control\Video\{*},call EnumVideoKeys
  48. enumregcmd HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Reinstall\{*},call DelReinstallKeys
  49. set RegPath=HKCU\Software\Microsoft\Windows\ShellNoRoam\MUICache
  50. EnumRegNamesCmd {RegPath}, if {current Reg Value}%NVIDIA then delreg {RegPath}\{Current Reg Name}
  51.  
  52. Enumregcmd HKLM\SYSTEM\{*ControlSet}\Control\Class\{4D36E968-E325-11CE-BFC1-08002BE10318}\{*},call DelnvDualViewRegs
  53.  
  54. [DelnvDualViewRegs]
  55. GetReg ProviderName={Current Root Key}\{Current Reg Key}\ProviderName
  56. if {ProviderName}=NVIDIA then DelReg {Current Root Key}\{Current Reg Key}
  57.  
  58. [EnumVideoKeys]
  59. set MyBaseKey={Current Root Key}\{Current Reg Key}
  60. enumregcmd {MyBaseKey}\{*},call CheckNVIDIAVideoKeys
  61.  
  62. [CheckNVIDIAVideoKeys]
  63. GetReg Device Description={Current Root Key}\{Current Reg Key}\Device Description
  64. if {Device Description}%NVIDIA then delreg {MyBaseKey}
  65.  
  66. [DelReinstallKeys]
  67. GetReg ProviderName={Current Root Key}\{Current Reg Key}\ProviderName
  68. GetReg DeviceInstanceIds={Current Root Key}\{Current Reg Key}\DeviceInstanceIds
  69. GetReg Class=HKLM\SYSTEM\CurrentControlSet\Enum\{DeviceInstanceIds}\Class
  70. if {Class},{ProviderName}%Display,NVIDIA then DelReg {Current Root Key}\{Current Reg Key}
  71.  
  72. [Clean up registry]
  73. call RemoveInfFromRegistry
  74. DelReg HKLM\Software\Microsoft\Windows NT\CurrentVersion\OpenGLDrivers\RIVATNT
  75. DelReg HKLM\Software\Microsoft\Windows\CurrentVersion\Run\NvCplDaemon
  76. DelReg HKLM\Software\Microsoft\Windows\CurrentVersion\Run\nwiz
  77.  
  78. DelReg HKLM\HARDWARE\\RESOURCEMAP\\VIDEO\nv4
  79. DelReg HKLM\HARDWARE\\RESOURCEMAP\\VIDEO\nv
  80.  
  81. set RootKey=HKLM\SYSTEM\{*ControlSet}
  82. call EnumAndDeleteHWKeys
  83.  
  84. ; NvTweak
  85. DelReg HKCR\CLSID\{FFB699E0-306A-11d3-8BD1-00104B6F7516}
  86. set Current Root Key=HKLM
  87. set Current Reg Key=\Software\Microsoft\Windows\CurrentVersion
  88. call DeleteNTTweak
  89. set RootKey=HKCU
  90. call DeleteNTTweak
  91. EnumRegCmd HKU\\{*}\Software\Microsoft\Windows\CurrentVersion,Call DeleteNTTweak
  92.  
  93. [EnumAndDelProfileKeys]
  94. DelReg {RegPath}\{*}\System\CurrentControlSet\Services\nv4
  95. DelReg {RegPath}\{*}\System\CurrentControlSet\Services\nv
  96.  
  97. [EnumAndDeleteHWKeys]
  98. DelReg {RootKey}\Services\nv4
  99. DelReg {RootKey}\Services\EventLog\System\nv4
  100. DelReg {RootKey}\Enum\Root\LEGACY_NV4
  101. DelReg {RootKey}\Services\nv
  102. DelReg {RootKey}\Services\EventLog\System\nv
  103. DelReg {RootKey}\Enum\Root\LEGACY_NV
  104. set RegPath={RootKey}\Services
  105. DelReg {RegPath}\nvcap
  106. DelReg {RegPath}\nvtunep
  107. DelReg {RegPath}\tvsnd
  108. DelReg {RegPath}\nvxbar
  109. set RegPath={RootKey}\Enum\DISPLAY
  110. DelReg {RegPath}\nvcap
  111. DelReg {RegPath}\nvtunep
  112. DelReg {RegPath}\tvsnd
  113. DelReg {RegPath}\nvxbar
  114. DelReg {RegPath}\nvMultiView
  115. set RegPath={RootKey}\Hardware Profiles
  116. call EnumAndDelProfileKeys
  117. DelReg {RootKey}\Control\Class\{4D36E968-E325-11CE-BFC1-08002BE10318}\{*}\CoInstallers32
  118. DelReg {RootKey}\Control\Class\{4D36E968-E325-11CE-BFC1-08002BE10318}\{*}\Uninstall
  119. EnumRegCmd HKLM\SYSTEM\{*ControlSet}\Control\Class\{4D36E96C-E325-11CE-BFC1-08002BE10318}\{*},Call CheckWDMDriver
  120.  
  121. [CheckDriver]
  122. GetReg Class={Current Root Key}\{Current Reg Key}\class
  123. GetReg Mfg={Current Root Key}\{Current Reg Key}\Mfg
  124. if {Class},{Mfg}=Display,NVIDIA then DelReg {Current Root Key}\{Current Reg Key}
  125.  
  126. [CheckWDMDriver]
  127. GetReg ProviderName={Current Root Key}\{Current Reg Key}\ProviderName
  128. GetReg MatchingDeviceId={Current Root Key}\{Current Reg Key}\MatchingDeviceId
  129. if {ProviderName},{MatchingDeviceId}=nVidia,display\nvcap then DelReg {Current Root Key}\{Current Reg Key}
  130. if {ProviderName},{MatchingDeviceId}=nVidia,display\nvxbar then DelReg {Current Root Key}\{Current Reg Key}
  131. if {ProviderName},{MatchingDeviceId}=nVidia,display\nvtunep then DelReg {Current Root Key}\{Current Reg Key}
  132. if {ProviderName},{MatchingDeviceId}=nVidia,display\nvtvsnd then DelReg {Current Root Key}\{Current Reg Key}
  133.  
  134. [DeleteNTTweak]
  135. delreg {Current Root Key}{Current Reg Key}\Controls Folder\Display\shellex\PropertySheetHandlers\NVIDIA CPL Extension
  136. delreg {Current Root Key}{Current Reg Key}\Run\Nv4QuickTweak
  137. delreg {Current Root Key}{Current Reg Key}\Run\Nv4ColorInit
  138. delreg {Current Root Key}{Current Reg Key}\Run\NvInitialize
  139. delreg {Current Root Key}{Current Reg Key}\Run\NvMediaCenter
  140. delreg {Current Root Key}{Current Reg Key}\Run\NvDeskMgrRestart
  141. delreg {Current Root Key}{Current Reg Key}\RunOnce\NvCplDaemon
  142. delreg {Current Root Key}{Current Reg Key}\RunOnce\nwiz
  143.  
  144. [DelNoneWorkStationKeys]
  145. DelReg  {Current Root Key}{Current Reg Key}\Global\NvSvc
  146. DelReg  {Current Root Key}{Current Reg Key}\Global\NVTweak
  147. DelReg  {Current Root Key}{Current Reg Key}\Global\NVDesk
  148. DelReg  {Current Root Key}{Current Reg Key}\Global\Setup
  149. DelReg  {Current Root Key}{Current Reg Key}\Global\MediaCenterTray
  150. DelReg  {Current Root Key}{Current Reg Key}\Global
  151. DelRegE {Current Root Key}{Current Reg Key}
  152.  
  153.  
  154. [DeleteFiles]
  155. ; delete oem*.inf files that have the following information
  156. ; wildcard for filename, section1,variable1,value1 [,section2,variable2,value2[,...]]  
  157. DelOemInfs nv*,Version,Class,Display,Version,Provider,%NVIDIA%
  158. DelOemInfs nv*,Version,Class,Display,Strings,Mfg,NVIDIA
  159. DelOemInfs nv*,Version,Class,Media,Strings,MS,nVidia
  160. DelIniIfMatched {windir}\INF\INTERNET\NVIDIA*.INF,Version,Class,Display
  161.  
  162. set BasePath={sysdir}
  163. DelBoot {basepath}\nv4_disp.dll
  164. DelBoot {basepath}\nvdccapp.cfg
  165. DelBoot {basepath}\nvwsapps.cfg
  166. DelBoot {basepath}\nvtuicpl.cpl
  167. DelBoot {basepath}\nvcpl.dll
  168. DelBoot {basepath}\nview.dll
  169. DelBoot {basepath}\nview64.dll
  170. DelBoot {basepath}\nviewimg.dll
  171. DelBoot {basepath}\nvwimg64.dll
  172. DelBoot {basepath}\nviewx.dll
  173. DelBoot {basepath}\nvinstnt.dll
  174. DelBoot {basepath}\nvmctray.dll
  175. DelBoot {basepath}\nvnt4cpl.dll
  176. DelBoot {basepath}\nvoglnt.dll
  177. DelBoot {basepath}\nvshell.dll
  178. DelBoot {basepath}\nvwddi.dll
  179. DelBoot {basepath}\nvwddi64.dll
  180. DelBoot {basepath}\nvwdmcpl.dll
  181. DelBoot {basepath}\dmcpl.exe
  182. DelBoot {basepath}\keystone.exe
  183. DelBoot {basepath}\nvappbar.exe
  184. DelBoot {basepath}\nvsvc.exe
  185. DelBoot {basepath}\nvsvc32.exe
  186. DelBoot {basepath}\nwiz.exe
  187. DelBoot {basepath}\aliagp.sys
  188. DelBoot {basepath}\drivers\nv4_mini.sys
  189. DelBoot {basepath}\drivers\nvcap.sys
  190. DelBoot {basepath}\drivers\nvxbar.sys
  191. DelBoot {basepath}\drivers\nvtvsnd.sys
  192. DelBoot {basepath}\drivers\nvtunep.sys
  193. DelBoot {basepath}\filter.ax
  194. DelBoot {basepath}\nvcod.dll
  195. DelBoot {basepath}\nvcodins.dll
  196. DelBoot {basepath}\nvapps.xml
  197.  
  198. DelBoot {basepath}\nvarch16.dll
  199. DelBoot {basepath}\nvarch32.dll
  200. DelBoot {basepath}\nvdd32.dll
  201. DelBoot {basepath}\nvmode.dll
  202. DelBoot {basepath}\nvopengl.dll
  203. DelBoot {basepath}\nvdisp.drv
  204. DelBoot {basepath}\agart.vxd
  205. DelBoot {basepath}\nvcore.vxd
  206. DelBoot {basepath}\nvmini.vxd
  207. DelBoot {basepath}\nvmini2.vxd
  208. DelBoot {basepath}\alipcimp.pci
  209. DelBoot {basepath}\nvinst32.dll
  210. DelBoot {basepath}\nvgfx.dll
  211.  
  212. DelBoot {sysdir}\dllcache\nv4_mini.sys
  213. DelBoot {sysdir}\dllcache\nv4_disp.dll
  214.  
  215. DelBoot {syswow64dir}\nvogl32.dll
  216. DelBoot {syswow64dir}\nview.dll
  217. DelBoot {syswow64dir}\nvwdmcpl.dll
  218. DelBoot {syswow64dir}\nvappbar.exe
  219. DelBoot {syswow64dir}\nviewimg.dll
  220. DelBoot {syswow64dir}\nvnt4cpl.dll
  221. DelBoot {syswow64dir}\nvwddi.dll
  222. DelBoot {syswow64dir}\nwiz.exe
  223. DelBoot {syswow64dir}\keystone.exe
  224.  
  225. ; Resource DLLs
  226. DelBoot {basepath}\nvrsar.dll
  227. DelBoot {basepath}\nvrscs.dll
  228. DelBoot {basepath}\nvrsda.dll
  229. DelBoot {basepath}\nvrsde.dll
  230. DelBoot {basepath}\nvrsel.dll
  231. DelBoot {basepath}\nvrseng.dll
  232. DelBoot {basepath}\nvrses.dll
  233. DelBoot {basepath}\nvrsesm.dll
  234. DelBoot {basepath}\nvrsfi.dll
  235. DelBoot {basepath}\nvrsfr.dll
  236. DelBoot {basepath}\nvrshe.dll
  237. DelBoot {basepath}\nvrshu.dll
  238. DelBoot {basepath}\nvrsit.dll
  239. DelBoot {basepath}\nvrsja.dll
  240. DelBoot {basepath}\nvrsko.dll
  241. DelBoot {basepath}\nvrsnl.dll
  242. DelBoot {basepath}\nvrsno.dll
  243. DelBoot {basepath}\nvrspl.dll
  244. DelBoot {basepath}\nvrspt.dll
  245. DelBoot {basepath}\nvrsptb.dll
  246. DelBoot {basepath}\nvrsru.dll
  247. DelBoot {basepath}\nvrssk.dll
  248. DelBoot {basepath}\nvrssl.dll
  249. DelBoot {basepath}\nvrssv.dll
  250. DelBoot {basepath}\nvrstr.dll
  251. DelBoot {basepath}\nvrszhc.dll
  252. DelBoot {basepath}\nvrszht.dll
  253.  
  254. ; nView Resource DLLs
  255. DelBoot {basepath}\nvwrsar.dll
  256. DelBoot {basepath}\nvwrscs.dll
  257. DelBoot {basepath}\nvwrsda.dll
  258. DelBoot {basepath}\nvwrsde.dll
  259. DelBoot {basepath}\nvwrsel.dll
  260. DelBoot {basepath}\nvwrseng.dll
  261. DelBoot {basepath}\nvwrses.dll
  262. DelBoot {basepath}\nvwrsesm.dll
  263. DelBoot {basepath}\nvwrsfi.dll
  264. DelBoot {basepath}\nvwrsfr.dll
  265. DelBoot {basepath}\nvwrshe.dll
  266. DelBoot {basepath}\nvwrshu.dll
  267. DelBoot {basepath}\nvwrsit.dll
  268. DelBoot {basepath}\nvwrsja.dll
  269. DelBoot {basepath}\nvwrsko.dll
  270. DelBoot {basepath}\nvwrsnl.dll
  271. DelBoot {basepath}\nvwrsno.dll
  272. DelBoot {basepath}\nvwrspl.dll
  273. DelBoot {basepath}\nvwrspt.dll
  274. DelBoot {basepath}\nvwrsptb.dll
  275. DelBoot {basepath}\nvwrsru.dll
  276. DelBoot {basepath}\nvwrssk.dll
  277. DelBoot {basepath}\nvwrssl.dll
  278. DelBoot {basepath}\nvwrssv.dll
  279. DelBoot {basepath}\nvwrstr.dll
  280. DelBoot {basepath}\nvwrszhc.dll
  281. DelBoot {basepath}\nvwrszht.dll
  282.  
  283. ; Help Files
  284. set BasePath={windir}\help
  285. DelBoot {basepath}\nv3tweak.hlp
  286. DelBoot {basepath}\nvcpar.hlp
  287. DelBoot {basepath}\nvcpcs.hlp
  288. DelBoot {basepath}\nvcpda.hlp
  289. DelBoot {basepath}\nvcpde.hlp
  290. DelBoot {basepath}\nvcpel.hlp
  291. DelBoot {basepath}\nvcpeng.hlp
  292. DelBoot {basepath}\nvcpes.hlp
  293. DelBoot {basepath}\nvcpesm.hlp
  294. DelBoot {basepath}\nvcpfi.hlp
  295. DelBoot {basepath}\nvcpfr.hlp
  296. DelBoot {basepath}\nvcpfr.hlp
  297. DelBoot {basepath}\nvcphe.hlp
  298. DelBoot {basepath}\nvcphu.hlp
  299. DelBoot {basepath}\nvcpit.hlp
  300. DelBoot {basepath}\nvcpja.hlp
  301. DelBoot {basepath}\nvcpko.hlp
  302. DelBoot {basepath}\nvcpl.hlp
  303. DelBoot {basepath}\nvcpnl.hlp
  304. DelBoot {basepath}\nvcpno.hlp
  305. DelBoot {basepath}\nvcppl.hlp
  306. DelBoot {basepath}\nvcppt.hlp
  307. DelBoot {basepath}\nvcpptb.hlp
  308. DelBoot {basepath}\nvcpru.hlp
  309. DelBoot {basepath}\nvcpsk.hlp
  310. DelBoot {basepath}\nvcpsl.hlp
  311. DelBoot {basepath}\nvcpsv.hlp
  312. DelBoot {basepath}\nvcpth.hlp
  313. DelBoot {basepath}\nvcptr.hlp
  314. DelBoot {basepath}\nvcpzhc.hlp
  315. DelBoot {basepath}\nvcpzht.hlp
  316.  
  317. ; nView Help Files
  318. DelBoot {basepath}\nvwcpar.hlp
  319. DelBoot {basepath}\nvwcpcs.hlp
  320. DelBoot {basepath}\nvwcpda.hlp
  321. DelBoot {basepath}\nvwcpde.hlp
  322. DelBoot {basepath}\nvwcpel.hlp
  323. DelBoot {basepath}\nvwcpeng.hlp
  324. DelBoot {basepath}\nvwcpes.hlp
  325. DelBoot {basepath}\nvwcpesm.hlp
  326. DelBoot {basepath}\nvwcpfi.hlp
  327. DelBoot {basepath}\nvwcpfr.hlp
  328. DelBoot {basepath}\nvwcpfr.hlp
  329. DelBoot {basepath}\nvwcphe.hlp
  330. DelBoot {basepath}\nvwcphu.hlp
  331. DelBoot {basepath}\nvwcpit.hlp
  332. DelBoot {basepath}\nvwcpja.hlp
  333. DelBoot {basepath}\nvwcpko.hlp
  334. DelBoot {basepath}\nvwcplen.hlp
  335. DelBoot {basepath}\nvwcpnl.hlp
  336. DelBoot {basepath}\nvwcpno.hlp
  337. DelBoot {basepath}\nvwcppl.hlp
  338. DelBoot {basepath}\nvwcppt.hlp
  339. DelBoot {basepath}\nvwcpptb.hlp
  340. DelBoot {basepath}\nvwcpru.hlp
  341. DelBoot {basepath}\nvwcpsk.hlp
  342. DelBoot {basepath}\nvwcpsl.hlp
  343. DelBoot {basepath}\nvwcpsv.hlp
  344. DelBoot {basepath}\nvwcpth.hlp
  345. DelBoot {basepath}\nvwcptr.hlp
  346. DelBoot {basepath}\nvwcpzhc.hlp
  347. DelBoot {basepath}\nvwcpzht.hlp
  348.  
  349. ; Other files
  350. DelBoot {basepath}\nvmontrs.cfg
  351. DelBoot {basepath}\nv3api.dll
  352. DelBoot {basepath}\nv3dd32.dll
  353. DelBoot {basepath}\nv3ogl.dll
  354. DelBoot {basepath}\nv3qtwk.dll
  355. DelBoot {basepath}\nv3rm.vxd
  356. DelBoot {basepath}\nv3sys.dll
  357. DelBoot {basepath}\nv3tweak.dll
  358. DelBoot {basepath}\nv4_kdisp.dll 
  359. DelBoot {basepath}\nvdesk32.dll
  360. DelBoot {basepath}\nvdmcpl.dll
  361. DelBoot {basepath}\nvds15.dll
  362. DelBoot {basepath}\nvdspmgr.dll
  363. DelBoot {basepath}\nvogl32.dll
  364. DelBoot {basepath}\nvqtwk.dll
  365. DelBoot {basepath}\nvstercp.dll
  366. DelBoot {basepath}\nvstercp.dll
  367. DelBoot {basepath}\nvstres.dll
  368. DelBoot {basepath}\maxtreme.drv
  369. DelBoot {basepath}\nv3disp.drv
  370. DelBoot {basepath}\nvfsvm.exe
  371. DelBoot {basepath}\nvsttest.exe
  372. DelBoot {basepath}\nvstview.exe
  373. DelBoot {basepath}\quadroview.exe
  374. DelBoot {basepath}\nvdual.sys
  375. DelBoot {basepath}\nv3.vxd
  376. DelBoot {basepath}\nv3mini2.vxd
  377.  
  378. ;for older stuff we just delete them right away
  379. Del {sysdir}\nvsys\nvinst32.dll 
  380. Del {sysdir}\nvsys
  381.  
  382. [RemoveInfFromRegistry]
  383. DelReg HKLM\Software\Microsoft\Windows\CurrentVersion\Setup\SetupX\INF\OEM Name\{windir}\INF\nvaml.inf
  384.