Hi,
there is a problem with the TWebUpdate and custom prefixes in the target paths. If I add a file to the update project in the UpdateBuilder and define a custom prefix as a part of the target path, the file will be ignored by TWebUpdater's "NewVersionAvailable" check. This happens with all "File Update" types except "Unconditional Update". With the "Unconditional Update" everything works perfectly, but that's probably only because the file will be always updated with this update type.
Example: I add a new version of "libcef.dll" to the update project. The file can be defined with each of update types, since it has a version info also, among other things:
The OnConvertPrefix event looks like this:
procedure TMainForm.WebUpdaterConvertPrefix(Sender: TObject; var Path: string);
begin
Path := StringReplace(Path, '{USER_APPDATA_LOCAL}', ENV_USER_LOCAL_APPDATA_DIR, [rfReplaceAll]);
end;
No, when I check for new updates
if WebUpdater.NewVersionAvailable then
...
I get "false" each time. The same with "File Version Update" and "File Sized Update". It works fine with "Unconditional Update" only.
Am I doing something wrong or is there a bug in the TWebUpdate?
Thanks!