AUX File Writing Error
thewritersclub at gmail.com
thewritersclub at gmail.com
Thu Feb 15 00:03:31 EST 2007
Hi guys!
I'm new to python so please be aware that I'm probably missing the
obvious. Here's my problem...
>>> t = "AUX"
>>> f = open('c:\\' + t + '.csv', 'a')
Traceback (most recent call last):
File "<pyshell#37>", line 1, in <module>
f = open('c:\\' + t + '.csv', 'a')
IOError: [Errno 2] No such file or directory: 'c:\\AUX.csv'
>>> t = "A"
>>> f = open('c:\\' + t + '.csv', 'a')
>>>
As you can see python has no problem opening a file when t = "A", but
not when it is "AUX" (no "A.csv" or "AUX.csv" exists on the C:\ folder
prior to when these are run).
Is there any way I can create an "AUX.csv" file without the error?
Thanks,
Ryan
More information about the Python-list
mailing list