This is sort of a continuation of this question. I have a file that I want to include with my installation package (a .CHM help file) that I need to access during installation from code. It doesn't need to be installed to the user's machine. So I want to
- include the file in the installation package, probably uncompressed (so I guess I will do that with a [Files] ... external
flag).
- reference the file during installation with code like:
procedure HelpButtonOnClick (Sender: TObject) ;
var
ErrorCode : Integer ;
begin
ShellExecAsOriginalUser ('open', ExpandConstant ('{???}') + '\MyHelp.chm', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end ;
So can I reference the file before installation starts - i.e. before any files are copied to the user machine? How do I specify the path ExpandConstant ('{???}')
to the file? I have a help button on the wizard form that calls the above handler.