title: How to copy all table with python-docx?
body: <p>I use the <code>python-docx</code> library and I have a document named <code>file.docx</code>. I need to copy all the content of the <code>.docx</code> tables to <code>file.xlsx</code></p>
  
  <p>My code is</p>
  
  <pre><code>from docx import *
  f = open('file.docx')
  d = Document(f)
  ts = d.tables[1]
  print ts
  &lt;docx.table.Table object at 0xb691f7ac&gt;
  </code></pre>
  
  <p>However, <code>&lt;docx.table.Table object at 0xb691f7ac&gt;</code> does not contain the content. How can I get the contents of the table?</p>