How to generate hash for file
I want to add a non versioned file to an msi using a transform with Inst Ed. I know about the method using WiFilVer.vbs but searching this forum I found another script I just don't know how you are supposed to use it. I do not know VBS.
Dim FilePath : FilePath = WScript.Arguments(0)
Dim Installer : Set Installer = CreateObject("WindowsInstaller.Installer")
Dim Record : Set Record = Installer.FileHash(FilePath, 0)
Dim FileHash : FileHash = Record.StringData(1) & vbTab & Record.StringData(2) & vbTab & Record.StringData(3) & vbTab & Record.StringData(4)
WScript.Echo "FileHash: " & FileHash
0 Comments
[ + ] Show comments
Answers (4)
Please log in to answer
Posted by:
nheim
14 years ago
Hi Joe,
paste it in a text file with the extension .vbs.
Then remove this leftover from HTML cut and paste:
Save it.
Use it on a command line like this: yourname.vbs filetohash.xxx
That returns the hash in 4 parts.
Put the hash in a new line in the MsiFileHash table.
That's all.
Good luck.
Regards, Nick
paste it in a text file with the extension .vbs.
Then remove this leftover from HTML cut and paste:
Save it.
Use it on a command line like this: yourname.vbs filetohash.xxx
That returns the hash in 4 parts.
Put the hash in a new line in the MsiFileHash table.
That's all.
Good luck.
Regards, Nick
Posted by:
mayur_mak
14 years ago
Posted by:
AngelD
14 years ago
Posted by:
joedown
14 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.