Ron
Ron

Reputation: 143

python-docx will not autocomplete on IDEs

I recently started using python-docx to work with Word documents and for some reason, it doesn't show up in the autocomplete. I tried VSCode and PyCharm. Other added libraries autocomplete fine in both.

I found this issue, but it is closed and the response is to ask in SO. I would appreciate any help.

Also, if this doesn't work out, is there any other python library to work with docx?

Upvotes: 0

Views: 496

Answers (2)

user16458087
user16458087

Reputation:

use this line of code for import python-docx:

import docx.document as #any thig that you are comfortable whit it

import in this way and autocomplete will works.

I apologize for my weak language

Upvotes: 0

Nipun Thennakoon
Nipun Thennakoon

Reputation: 3734

I don't know the reason, but python-docx code completion works in pycharm console and IDLE. In IDLE, you have to press ctrl + space to obtain the pop up menu though. Hope this helps. :)

IDLE:

Pycharm console:

Upvotes: 1

Related Questions