Hi Susana,<br><br><div class="gmail_quote">On 5 September 2011 17:08, Susana Iraiis Delgado Rodriguez <span dir="ltr"><<a href="mailto:susana.delgado_s@utzmg.edu.mx">susana.delgado_s@utzmg.edu.mx</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"> File "win.py", line 43, in boton4<br><div> writer = csv.writer(open(csv_name, 'w'))<br>AttributeError: 'function' object has no attribute 'writer'</div>
<div>I read a tutorial and csv has a writer function, I'm lost</div><br></blockquote></div><br>Yes, the csv module has a writer function. But read carefully! The error message isn't saying that the csv module doesn't have a writer function -- it says **function object** has no attribute 'writer'. So... somehow Python thinks that the name 'csv' refers to a function at the point in the code where the error is thrown. So how can this be? You should be asking yourself this question -- could it be that you've (for example) defined a *function* called 'csv', thereby effectively effectively hiding the *module* csv? ;)<br>
<br>Walter<br>