02-07-2025 09:59 AM
In the VBS world of scripting it was possible to add a menu item via (https://forums.ni.com/t5/Example-Code/How-to-Add-a-New-Menu-Item-to-DIAdem/ta-p/3506442)
MenuItemInsert("VIEW", "7","PopUp","My Custom Functions")
Is there an equivalent method using the python interface? I'd like to avoid mixing VBS and python if at all possible.
03-20-2025 04:36 AM
Hello pcristini_hitachienergy,
Python was introduced in DIAdem 2020 as an alternative programming language, and it is now possible to use a Python interface to add a menu item.
In your case, I suggest selecting Python as the preferred scripting language. You can always modify your preferred scripting language in DIAdem at Settings » DIAdem Settings » SCRIPT.
You should just check that you have installed the Python module pywin32 and a version of Python that is supported by DIAdem. You will find more information about the integration of Python in DIAdem here.
Do not hesitate to ask further questions.