Sub Register(strFilePath,regMethod)
Dim theFile,strFile,oShell ,exitcode
Set theFile=oFs.GetFile(strFilePath)
strFile=theFile.Path
Set oShell=CreateObject("WScript.Shell")
If regMethod="REG" then
oShell.Run "C:\winnt\system32\regsvr32.exe /s" & strFile,0,False
exitcode=oShell.Run("C:\.........";0,False)
EchoB("regsvr32.exe exitcode=" & exitcode)
Else
oShell.Run "C:\winnt\system32\regsvr32.exe /u/s" & strFile,0,False
exitcode=oShell.Run("C:\........";0,False)
EchoB("regsvr32.exe exitcode=" & exitcode)
End If
Clearup oShell
End Sub