Sep-16-2017, 01:53 AM
I need to enter the path to the files I want to manipulate, by name pathToExcel, pathToPhotos. A few times I got it wrong and the program did not run. I had to start again.
What I would like is a little loop that prints the input, asks if it is correct, then proceeds. If the input is wrong, it should ask for new input.
I'm thinking along the lines of:
What I would like is a little loop that prints the input, asks if it is correct, then proceeds. If the input is wrong, it should ask for new input.
I'm thinking along the lines of:
while True: print('enter the path to the excel file or enter nothing to stop): ') path = input() print('Is this path correct? ' + path)but what should I put next? What is the best way to do this?