I'm trying to extract information from excel file, and eventually put the values from the excel in a docx file. when I wrote the code I entered a specific path using the syntax (r"file path), and I had no problem. because the program was created for a friend of mine, and it will run on a different computer, I am looking for a way for my friend to open the exact excel file he wanted. down below you can see some codes. thanks in advance to anybody that spend some time trying to solve it!
this one worked for me:
loc = (r"C:\Users\dddor\Desktop\python24\report_example.xlsx")
this one brings error:
loc=(input('enter file location: '))
I also tried, but same error poped:
loc=("r"+input('enter file location: '))
Even when I copy the file path, that worked for me (both with and without the "r" it doesn't work)