3

I have installed the newest QGIS and downloaded python-docx from this link python-docx . I haven't installed separately a different version of python. Is it possible to integrate this package of python-docx to work with QGIS (Windows version) ?

  1. I looked at this site Installing Third-party Python Modules in QGIS (Windows)
  2. After changing this section call(['easy_install', 'lxml']) to call(['easy_install', 'python-docx']) and run code in QGIS Python console I've got an error : enter image description here
  • Did you know how to install a Python module ? – gene May 21 '16 at 15:31
  • I did it on Virtual machine with portable python (and it works but only with python console). I don't know how to install this python module with QGIS. – Artec May 22 '16 at 9:39
  • There are many answers in GIS SE, look for example in QGIS docutils install (path,pythonpath,pythonhome) – gene May 22 '16 at 14:53
  • @gene I update my question. The problem is still not resolved. – Artec May 22 '16 at 18:49
0

you should use the following code, in osgeo shell(just check python 2.7 is not your default python in shell), or from pycharm terminal(after configuring pycharm to know your qgis 3 python following Setting up PyCharm for PyQGIS and Qt)

python3 -m pip install python-docx

just notice that the qgis 3 python console intellisense will not be updated, but in pycharm, yes, how ever the module import works for both.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.