Compiling .dll without restarting Rhino


I am compiling .dll library with some geometry helper functions.
I am not running the project in debugging mode. Just would like to add or change some bits of code in my .dll while working without restarting rhino.

The problem is that when I want to compile the code I need to close rhino else I get error in visual studio:
Could not copy "obj\Debug\RhinoJoint.dll" to "..\..\..\..\..\AppData\Roaming\Grasshopper\6\Libraries\RhinoJoint\RhinoJoint.dll". Exceeded retry count of 10. Failed. The file is locked by: "Rhino 6 (2364)" RhinoJoint

The .dll is loaded in grasshopper C# script editor, ideally I would like to update the .dll while working, but restarting rhino is what I would like to avoid.

Is there any workaround?

No, not that I know of…

– Dale

For what it’s worth, if you did run under the debugger, it may be possible to get edit & continue working.

This is for compiled components.
But also if you write a new method or class you need to restart.

I hope there was something similar like Unity compiler or python saving .py files.

Maybe this:

1 Like

We use this MEF-based method :arrow_double_up: and it saves a lot of time.