EOL - scanning single-quoted string

Ajay abra9823 at mail.usyd.edu.au
Wed Aug 4 09:20:59 EDT 2004


hi!

I am developing an application for a pocket pc.
i have a small gui which allows users to select files using a file dialog
box. however the file, selected is represented as '/My Documents/test'
which when i try to open gives me an error.
so what i would like to do is replace '/' by the windows '\'
however when i try
str='/My Documents/test'
re.subn('/', '\', str)

i get an error saying - SyntaxError: EOL while scanning single-quoted
string

how can i replace the slashes.

thanks

cheers

--
Ajay Brar,
CS Honours 2004
Smart Internet Technology Research Group





----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



More information about the Python-list mailing list