Set Sh = CreateObject("WScript.Shell")
key = "HKEY_CLASSES_ROOT\"
x=inputbox("Select your operating system:" & vbnewline & vbnewline & "1. Windows 98" & vbnewline & "2. Windows 2000" & vbnewline & "3. Windows XP" & vbnewline & "4. Other","OS")
if isnumeric(x) then
if x=1 or x=3 then
Sh.RegWrite key & "dllfile\shell\Register\command\", "C:\Windows\System32\Regsvr32.exe " & chr(34) & "%1" & chr(34), "REG_SZ"
Sh.RegWrite key & "dllfile\shell\Unregister\command\", "C:\Windows\System32\Regsvr32.exe /u " & chr(34) & "%1" & chr(34), "REG_SZ"
msgbox "The context menu has been added.", vbokonly+vbinformation, "Finished"
elseif x=2 then
Sh.RegWrite key & "dllfile\shell\Register\command\", "C:\WINNT\System32\Regsvr32.exe " & chr(34) & "%1" & chr(34), "REG_SZ"
Sh.RegWrite key & "dllfile\shell\Unregister\command\", "C:\WINNT\System32\Regsvr32.exe /u " & chr(34) & "%1" & chr(34), "REG_SZ"
msgbox "The context menu has been added.", vbokonly+vbinformation, "Finished"
else
msgbox "Sorry your OS is not currently supported.", vbokonly+vbinformation, "Sorry"
end if
else
msgbox "Please select an option form the list!", vbokonly+vbinformation, "Error"
end if
Save attatch text as RegistDll.VBS. then run this file, select the right operating system.
after that when you right click the XColor.dll file you will find the menu to register. |