I am not a big fan of the RhinoPythonEditor, so I am wondering if it is possible to let PyChamr do the same job? I followed the directions outlined in the following post:
However, when I run:
from Rhino import RhinoApp, RhinoDoc
gh = RhinoApp.GetPlugInObject("Grasshopper")
I get:
"C:\Program Files\IronPython 2.7\ipy.exe" E:/TEST_PROJECT_PYCHARM/TEST
Traceback (most recent call last):
File "E:/TEST_PROJECT_PYCHARM/TEST", line 6, in <module>
SystemError: Unable to load DLL 'rhcommon_c': A dynamic link library (DLL) initialization routine failed. (Exception from HRESULT: 0x8007045A)
Process finished with exit code 1
Hi you cannot directly load Rhinocommon.dll outside of a Rhino instance. This is what the error indirectly says. You can write the code in any editor, but it has to be executed within a Rhino instance. So you can run it from Rhino cmdline. Iâm not sure about the cmd. Must be something like: run python xyz.py .
Yes, you need to execute the script in Rhino in any case, in order for Rhino to load RhinoCommon.
Maybe for future versions, @stevebaer could investigate if the ExecuteFile-based method that is employed in the new GhPython is also applicable to the EditPythonScript editor.
From time to time I like come back in this forum to help out, because the forum helped me a lot in return⌠but sometimes, especially if people ignoring messages, I ask myself: What am I doing here? And I begin to wonder, why so many people have such a deficit in basic communication. âThank you, Tomâ (no matter if this answer was helpful enough) is really the minimum you could give in return. But even worse, saying thank you to another person which is saying the same as I said, tells me: I respect him, but not you!