TWUCheckUpdateVersion

The TWUCheckUpdateVersion compares the product version of a local file against the version of an update package. If the local file does not exist or does not have a VERSIONINFO resource, then it always compares as "older".

int TWUCheckUpdateVersion(
    const TCHAR *pszLocalPath,
    const TWUPackageData *pPackage
);

Delphi version:

function TWUCheckUpdateVersion(
    pszLocalPath: PTCHAR;
    pPackage: PTWUPackageData
): Integer;

Parameters

pszLocalPath
[Input] Fully qualified path to the local file whose version must be compared.
pPackage
[Input] Pointer to the package information whose version must be compared.

Return value

Returns <0 if the local file is older than the package version; 0 if equal; >0 if the local file is newer than the package version.