confusion about opening files

Erik Max Francis max at alcyone.com
Tue Sep 24 04:37:39 CEST 2002


robie1373 wrote:

	...
>     file = os.open("e:\\d12", "r")
> TypeError: an integer is required
> 
> I get this error if the mode is r, r+, a+ or whatever.  I also get it
> whether the file exists or not. Can someone explain what I am doing
> wrong?

You meant open, not os.open.

-- 
 Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
 __ San Jose, CA, US / 37 20 N 121 53 W / ICQ16063900 / &tSftDotIotE
/  \ Insight -- the titillating knack for hurting!
\__/ Colette
    Erik Max Francis' bookmarks / http://www.alcyone.com/max/links/
 A highly categorized list of Web links.



More information about the Python-list mailing list