I created a program for when the user runs it, it emails an attachment to him/her self. The code right is when a different user runs it, the code needs to be change to the different user (which is not efficient). Is there a python code to identify the person running the program's outlook email address and sends it to him/her self. I am using win32com.
instead of
mail.to "email address"
to
mail.to "user of the program"