I'm use py2exe to create a .exe file so that someone without Python on their computer can run a script. Because I'm creating an alias (shortcut) of the .exe file, I need to hardcode the path to the folder containing the files that the python script targets. I also need to make sure that it will work on anyone's desktop (regardless of username) and work in a folder called Reports. I tried using the following line of code but I got an invalid syntax error:
cwd = r"os.path.expanduser("~/Desktop/Reports")"
I wondered if anyone could provide any advice to help solve this?
Thanks in advance