[Python] Python - I am trying to copy and paste below file into my h drive, which is the...

Discussão em 'Python' iniciado por Stack, Agosto 1, 2025.

  1. Stack

    Stack Membro Participativo

    I am trying to copy and paste a file into my h: drive, which is a personal drive. I am getting the following error:

    target = (r'H:\')
    SyntaxError: EOL while scanning string literal


    Here is my code :

    import shutil

    original = (r'H:\Bulk upload\filetocopy.xlsx')
    target = (r'H:\')
    shutil.copyfile(original,target)

    Continue reading...

Compartilhe esta Página