The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 895 - File: showthread.php PHP 7.2.34 (Linux)
File Line Function
/showthread.php 895 errorHandler->error

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Execute Python code in QM
Macro Python scripting help
Copy      Help
;These functions can be used to execute Python code in QM.


;1. Download and install Python 32-bit Windows version from
;;;;IMPORTANT: When installing, check "Add to PATH". After installing, restart QM to update its copy of PATH variable.
;2. Download and install pywin32 from
;;;;Choose the version that matches your Python version, for example pywin32-224.win32-py3.7.exe for Python 3.7.x.
;;;;Run the setup program as administrator.

;I tested Python version 3.7.2 on Windows 10, 7 and 8.1. Works without problems.
;In the past I also tested version 3.5.2 and encountered various problems, but finally it worked on Windows 10 and 7. Version 3.4.3 worked without problems on Windows 10, 7 and 8.1. I didn't test 64-bit version, it probably would not work with QM.


;Run macros in "test" folder.

Use the above SETUP instructions. The SETUP instructions in the downloaded macro are now obsolete.

Attached Files
.qml   Python.qml (Size: 10 KB / Downloads: 719)

Messages In This Thread

Forum Jump:

Users browsing this thread: 1 Guest(s)