title: append rows in Excel using XLWT in Python
body: <p>How to find total number of rows using XLWT or XLRD in Python? I have an excel file(accounts.xls) and would like to append rows in it. </p>
  
  <p>I am getting an error here - AttributeError: 'Sheet' object has no attribute 'write'</p>
  
  <pre><code>from xlrd import open_workbook
  from xlwt import Workbook
  def saveWorkSpace(fields,r):
      wb = open_workbook('accounts.xls')
      ws = wb.sheet_by_index(0)
      r = ws.nrows
      r += 1
      wb = Workbook()
      ws.write(r,0,fields['name'])
      ws.write(r,1,fields['phone'])
      ws.write(r,2,fields['email'])
      wb.save('accounts.xls')
      print 'Wrote accounts.xls'
  </code></pre>