Path to Users <username> Documents

I have tried help docs and forum without success on this question.

I need to access and write data (csv file) to users document folder.

Building (or should say attempting) program that will be ran on school laptops. Every teacher has the csv file with their data and no issue, got the php script working but cannot seem to get path correct.

Just need to tell php script the correct path to “Users<username>\Documents\Personal Calendar\data.csv”

Saw this, but cannot get anything out of it:

Mind pointing me in right direction? Maybe example?

Thank you!

getenv("HOMEDRIVE") . getenv("HOMEPATH"). "\\Documents\\Personal Calendar\\data.csv";

Perfect, thank you!

I was on right track or at least close, but the double \ \ solved the issue (and another unrelated one).

While on the subject of paths, could you share PHP path to:

Users > Public > Public Documents

Like to have that info for future reference. This is same place that EXEOut places “Samples”.

I tired the below but not found (fatal error) even though folder is in place:

getenv("PUBLIC"). "\\Public Documents\\EXEOut Test\\test.txt

BTW: I tried to search online support doc but get:
Unauthorized access to internal API. Please refer to

Cannot use built-in help for EXEOut either. EXEOut hangs (not responding) and must force close.

Put this in your UserMain script (go to the Application Settings => Scripting, double click on “UserMain”)

function GetPublicDocPath: String;
Result := GetSpecialFolderPath(46);

Then you can get the path in PHP thanks to:
$path = exo_return_hescriptcom ('UserMain.GetPublicDocPath', '');

1 Like

This will be fixed in next doc. update. Google changed their API.

Again, thank you for taking time to show this, much appreciated.

Hey @gdgsupport

Working on app for classroom and having issue with AppData folder.

The students have a “slave” EXEOut built software installed and teacher has a “master” installed. The “master” makes changes to a database in “slaves” AppData folder.

The issue I am having is finding correct path to “slaves” AppData folder.

Let’s say I am using the general demo example:


Is there similar string like “GetSpecialFolderPath(46);” talked about above?

Cannot find a KNOWNFOLDERID for ((%USERPROFILE%\AppData\Local))

Stuck and appreciate some input.

Thanks in advance!

Yes, use GetSpecialFolderPath(28) and you will get C:\Users\oleteacher\AppData\Local\

Thank you!