When writing text. . .
Ivan Shevanski
darkpaladin79 at gmail.com
Fri Jul 14 17:05:56 EDT 2006
Hey I'm pretty new to python and I have a question. I'm trying to write:
"[BOOT]
run=C:\windows\aawin.bat"
in my win.ini
So I went about it like this:
win = open('C:\windows\win.ini', 'a')
win.write('[BOOT]')
win.write('\n')
win.write('run=C:\windows\aawin.bat')
I expected that to work, but instead of C:\windows\aawin.bat I get
run=C:\windowsawin.bat. . .
I assume /a is a code for like /n is for a newline, is there a way to fix
this?
Thanks in advance,
-Ivan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20060714/950fa28c/attachment.html>
More information about the Python-list
mailing list