一、将以下内容另存为uninstall.vbs,并放在网站相同的目录下。
On Error Resume Next
Set sss = CreateObject("WScript.Shell")
rem 这是XX控件TestX.ocx,下面是你的控件的ID
ID="{19E2DF33-1044-427F-AE24-BA9EE149B014}"
mhk="HKEY_CLASSES_ROOT/CLSID/"&ID
sss.RegDelete mhk&"/Control/"
sss.RegDelete mhk&"/InprocServer32/ThreadingModel"
FName=r.RegRead(mhk&"/InprocServer32/")
r.RegDelete mhk&"/InprocServer32/"
r.RegDelete mhk&"/MiscStatus/1/"
r.RegDelete mhk&"/MiscStatus/"
r.RegDelete mhk&"/ProgID/"
r.RegDelete mhk&"/ToolboxBitmap32/"
r.RegDelete mhk&"/TypeLib/"
r.RegDelete mhk&"/Verb/0/"
r.RegDelete mhk&"/Verb/"
r.RegDelete mhk&"/Version/"
r.RegDelete mhk&"/"
Set objFs=CreateObject("Scripting.FileSystemObject")
objFs.GetFile(FName).Delete
MsgBox "恭喜,"&CHR(13)&CHR(10)&ID&CHR(13)&CHR(10)&"注销成功。"
二、做好超级链接
注意:*.OCX需要关闭相关网页才能删除。