File\_GetVersion
Description
Section titled “Description”Returns the version of the specified file
Syntax
Section titled “Syntax”File_GetVersion(sFile, bMustExist) As Boolean
Parameters
Section titled “Parameters”sFile (String)
Filename
bMustExist (Boolean)
File must exist
Return value
Section titled “Return value”Result will be stored in gsValue. Function will return false if file does not exist and bMustExist is true
Example
Section titled “Example”VBScript
If bStatus Then bStatus = File_GetVersion(gsProgramFiles & "\CapaInstaller\Agent\CIAgent.exe", True)If bStatus Then bStatus = Job_Writelog("Custom", "Current version of CIAgent.exe is : " & gsValue, bStatus, True)Related functions
Section titled “Related functions”File_GetFileDateCreated File_GetSecurity File_GetShortPath