That it doesn't work is a big surprise indeed
;Call ExpandEnvironmentStringsA
call [ebp+0x10]What is that, an attempt to cheat the AV brigade?
GetFilePAth:What's your error message on that, "symbol not found"?
call FilePAthReturn
db "%appdata%\xxx.xx"So Nasm knows by some magic that these two lines are in different segments?
Where did you copy that code from? Or do you pretend it's your own, and you understand what you are doing??