It explains how PHP can access external files (which means files not compiled into the EXE).
For your case, to open any text file provided you know the location, do this:
Create the HEScript function. Open your ExeOutput project and go to the Scripting page. Double-click the “UserMain” script to open the script editor.
Add this function code:
procedure OpenAFile(Filepath: String);
res := OpenFile(FilePath, “”, SW_SHOWNORMAL);
if res < 32 then
MessageBox("Error while opening: " + FilePath + ". Error code: " + inttostr(res), “Launch Error”, MB_OK+MB_ICONERROR);
Click Save Script.
Edit the HTML page with the links that should open the file. Just replace the links with the HTML code:
<a href="hescript://UserMain.OpenAFile|PATH TO YOUR DOCUMENT">Open my document</a>
In your case, this would be:
<a href="hescript://UserMain.OpenAFile|D%3A%5Cmore%5Csal.txt">Open my document</a>
As you can see the path D:/more/sal.txt has been encoded for URLs: D%3A%5Cmore%5Csal.txt