- Wrap the file name in quotation marks like this
"your file.txt"
- If you have a filepath, use the raw string (and backslashes in the copied filepath) by placing a
r
before the quotation marks:
r"C:\Folder\Subfolder\another_one\your_file.txt"
solved how to import .txt with space in filename