<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How do you deal with .net assembly locking (making changes without restarting autocad)? in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13806674#M85741</link>
    <description>&lt;P&gt;after two days of running autocad I must admit that compared to revit an occasional restart is actually fairly feasible - it's only about 10-30 seconds for most sheet sets&lt;/P&gt;</description>
    <pubDate>Thu, 11 Sep 2025 16:07:14 GMT</pubDate>
    <dc:creator>baleti3266</dc:creator>
    <dc:date>2025-09-11T16:07:14Z</dc:date>
    <item>
      <title>How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801043#M85707</link>
      <description>&lt;P&gt;I'm wondering if there is some established solution already to NETLOAD without locking a .dll assembly. By default you can't recompile into a .dll that has been netloaded, because it's locked by autocad. I wrote an &lt;A href="https://github.com/baleti/autocad-ballet/blob/main/commands/InvokeAddinCommand.cs" target="_blank" rel="noopener"&gt;InvokeAddinCommand&lt;/A&gt; that loads dll as bytes and runs command without actually opening and locking a .dll. But I'm wondering if this is reinventing a wheel and someone has done something like this already?&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 12:53:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801043#M85707</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-08T12:53:19Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801273#M85708</link>
      <description>&lt;P&gt;Sounds like you're trying to debug with &lt;A href="https://learn.microsoft.com/en-us/visualstudio/debugger/how-to-enable-and-disable-edit-and-continue?view=vs-2022" target="_blank" rel="noopener"&gt;edit and continue.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://keanw.com/2008/09/tired-of-not-be.html" target="_blank"&gt;https://keanw.com/2008/09/tired-of-not-be.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 15:05:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801273#M85708</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-08T15:05:07Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801494#M85710</link>
      <description>&lt;P&gt;I've looked into debugging with edit and continue (I believe they call&amp;nbsp; it hot reloading now?), but it's not the same as simply rerunning your new command from an updated dll. Practically, there is a lag of 2&amp;nbsp; to 10 seconds to attach a debugger to autocad/revit process - rerunning a new dll is well instantaneous, which can make a difference when you suck at coding like me &lt;span class="lia-unicode-emoji" title=":face_with_tongue:"&gt;😛&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 17:12:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801494#M85710</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-08T17:12:28Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801539#M85711</link>
      <description>&lt;P&gt;I don't have an issue with edit and continue... huh... so &lt;EM&gt;that's&lt;/EM&gt; why I'm not better at coding?! &lt;span class="lia-unicode-emoji" title=":grinning_face_with_sweat:"&gt;😅&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jokes aside, perhaps someone smarter than I will be along shortly to offer something more helpful.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 17:46:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801539#M85711</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-08T17:46:10Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801731#M85712</link>
      <description>&lt;P&gt;&amp;gt;&amp;nbsp;&lt;SPAN&gt;so&amp;nbsp;&lt;/SPAN&gt;&lt;EM&gt;that's&lt;/EM&gt;&lt;SPAN&gt;&amp;nbsp;why I'm not better at coding&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;actually that would mean that you are better (in all honesty, if you are able to develop with just the debugger and restarting autocad each time I'm somewhat impressed and a little scared)&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 20:02:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801731#M85712</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-08T20:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801870#M85713</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/16639190"&gt;@baleti3266&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&amp;gt;&amp;nbsp;&lt;SPAN&gt;so&amp;nbsp;&lt;/SPAN&gt;&lt;EM&gt;that's&lt;/EM&gt;&lt;SPAN&gt;&amp;nbsp;why I'm not better at coding&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;actually that would mean that you are better (in all honesty, if you are able to develop with just the debugger and restarting autocad each time I'm somewhat impressed and a little scared)&lt;/SPAN&gt;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;That's kind of you to say... before I had a kid and grew up, that would totally have been signature inspo Haha... &lt;EM&gt;'BB is somewhat impressive and a little scary' ~ baleti3266&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess I (still?) do that, as I've never seen a different/better way, TBH.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I know that VS can attach to a process. I've never really done it, as it was my understanding (correct me where I'm wrong), that the DLL loaded once you attach stays loaded when you detach. Debug &amp;amp; launch works fine for me (since edit &amp;amp; continue) mainly so I can be working (I'm a civil designer), pause on that session to test code in a new session, without leaving a new assembly loaded in my production instance, if that makes sense.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In any event, I genuinely appreciate the interesting topic. &lt;span class="lia-unicode-emoji" title=":beer_mug:"&gt;🍺&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Perhaps&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/109424"&gt;@_gile&lt;/a&gt;&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/543921"&gt;@norman.yuan&lt;/a&gt;&amp;nbsp;can provide actual help.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;</description>
      <pubDate>Mon, 08 Sep 2025 22:54:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801870#M85713</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-08T22:54:45Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801958#M85714</link>
      <description>&lt;P&gt;hah thanks, I may have to give debugging another try then&lt;/P&gt;&lt;P&gt;method I was using feels "hacky", at startup autolisp (acad.lsp) copies .dll into a temporary directory and netloads it, so that each autocad process has its own copy. In addition to that running InvokeAddinCommand can make another copy directly in process memory (reads raw bytes from .dll) and executes that instead of locking the file and does so each time .dll changes (if it doesn't change it uses previous in-memory version). This way you can compile to hearts content without attaching debugger to autocad process and once ready the next time autocad starts it will have the updated version&lt;BR /&gt;&lt;BR /&gt;just finished updating this first bit actually:&amp;nbsp;&amp;nbsp;&lt;A href="https://github.com/baleti/autocad-ballet/commit/72ff37108ab7914e80a5b9af70d3bb625f2cef58#diff-93a8b97c16fc80016c09c38f7eb45428d890481dbcd49407454fa73ff3b05e38" target="_blank" rel="noopener"&gt;Commit 72ff371&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 09 Sep 2025 00:52:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13801958#M85714</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-09T00:52:39Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13802006#M85715</link>
      <description>&lt;P&gt;I'm a fan of the Autoloader mechanism, especially as it allows custom sysvars to be implemented incredibly easily.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That said, for a 'sandbox' VS solution apart from my production builds, I simply block comment out the assembly loading Component from PackageContents.xml (so my main session doesn't load the sandbox assembly, it's fine if they load the sysvars, etc), then in the VS debug properties, command line arguments, I include a /b switch call to load a simple .SCR that then NETLOADs the assembly (which itself builds to the Autoloader app .bundle).&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Silo for when I need to work through the plugin idea, then easily un-block comment the Component in PackageContents.xml when ready for production, and you've got yourself an app to distribute.&lt;/P&gt;</description>
      <pubDate>Tue, 09 Sep 2025 01:41:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13802006#M85715</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-09T01:41:21Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13802942#M85724</link>
      <description>&lt;P&gt;interesting, thanks - that's a quite different process. I guess if you know your code well that's fine, but the overhead of restarting autocad, commenting out Component in PackageContents.xml and attaching debugger (I assume .scr+netload step is instanenous though) each time is a bit much for me. Especially when it seems that you can just recompile and run .dll in a single command and in current session. Then again, I'm mostly "vibecoding" through claude, so my attention span isn't great.&lt;/P&gt;</description>
      <pubDate>Tue, 09 Sep 2025 12:39:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13802942#M85724</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-09T12:39:57Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13806674#M85741</link>
      <description>&lt;P&gt;after two days of running autocad I must admit that compared to revit an occasional restart is actually fairly feasible - it's only about 10-30 seconds for most sheet sets&lt;/P&gt;</description>
      <pubDate>Thu, 11 Sep 2025 16:07:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13806674#M85741</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-11T16:07:14Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13806718#M85742</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/16639190"&gt;@baleti3266&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;interesting, thanks - that's a quite different process. I guess if you know your code well that's fine, but the overhead of restarting autocad, commenting out Component in PackageContents.xml and attaching debugger (I assume .scr+netload step is instanenous though) each time is a bit much for me. Especially when it seems that you can just recompile and run .dll in a single command and in current session. Then again, I'm mostly "vibecoding" through claude, so my attention span isn't great.&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Perhaps I was unclear; while I'm 'sandboxing' a new app, I comment out the PackageContents.xml component for the assembly only (once). In VS, my plugin builds to the Autoloader app .bundle folder each time, for debug &amp;amp; release builds. Also in VS, my Debug settings include a /b switch to load a SCR located within my VS solution (which NETLOADs the new build for me on acad.exe session launch). This allows me to be working in one session with live project drawings, and debug in a separate session without needing to quit both on next debug. While debugging, I can edit and continue repeatedly within the same, single AutoCAD or Civil 3D session, until I either raise an exception I've not accounted for which crashes, or until I make another change that prevents edit and continue from working. I do NOT debug launch, test something, stop debugging, edit the code, debug launch again, etc. Not happening. Only when done debugging, and I'm ready to distribute the app .bundle, do I then make a final release build, and uncomment the assembly load component of PackageContents.xml (once).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;[Edit] - If &lt;EM&gt;anyone&lt;/EM&gt; has a better, more efficient way of doing this - please share it - if it only saves me 15 minutes a day, extrapolate that out, that's an extra +/- 1.5 weeks per year of time I get to spend with my family.&lt;/P&gt;&lt;HR /&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/16639190"&gt;@baleti3266&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;after two days of running autocad I must admit that compared to revit an occasional restart is actually fairly feasible - it's only about 10-30 seconds for most sheet sets&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I'm glad it's working faster for you than expected... AutoCAD.IsDefinitely != Revit&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;</description>
      <pubDate>Thu, 11 Sep 2025 16:44:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13806718#M85742</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-11T16:44:28Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13807970#M85749</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1206685"&gt;@BlackBox_&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Perhaps I was unclear; while I'm 'sandboxing' a new app, I comment out the PackageContents.xml component for the assembly only (once). In VS, my plugin builds to the Autoloader app .bundle folder each time, for debug &amp;amp; release builds. Also in VS, my Debug settings include a /b switch to load a SCR located within my VS solution (which NETLOADs the new build for me on acad.exe session launch). This allows me to be working in one session with live project drawings, and debug in a separate session without needing to quit both on next debug. While debugging, I can edit and continue repeatedly within the same, single AutoCAD or Civil 3D session, until I either raise an exception I've not accounted for which crashes, or until I make another change that prevents edit and continue from working. I do NOT debug launch, test something, stop debugging, edit the code, debug launch again, etc. Not happening. Only when done debugging, and I'm ready to distribute the app .bundle, do I then make a final release build, and uncomment the assembly load component of PackageContents.xml (once).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I recently create a package and a template to create AutoCAD plugins based in my Revit template.&lt;/P&gt;&lt;P&gt;&amp;nbsp;The video is in Portuguese but has auto-generate audio in English. And here is the template package: &lt;A href="https://github.com/ricaun-io/ricaun.Revit.Templates" target="_blank"&gt;https://github.com/ricaun-io/ricaun.Revit.Templates&lt;/A&gt;&lt;div class="video-embed-center video-embed"&gt;&lt;iframe class="embedly-embed" src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F0kh7asG-LA8%3Ffeature%3Doembed&amp;amp;display_name=YouTube&amp;amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D0kh7asG-LA8&amp;amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F0kh7asG-LA8%2Fhqdefault.jpg&amp;amp;type=text%2Fhtml&amp;amp;schema=youtube" width="200" height="112" scrolling="no" title="AutoCADAddin Template - Plugin para AutoCAD" frameborder="0" allow="autoplay; fullscreen; encrypted-media; picture-in-picture;" allowfullscreen="true"&gt;&lt;/iframe&gt;&lt;/div&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In that case I'm coping the&amp;nbsp;&lt;STRONG&gt;PackageContents.xml&lt;/STRONG&gt; and content every build, and the debug should open AutoCAD.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At the moment I don't have any way to hot-reload the AutoCAD plugin on runtime. Only way I know would be to create a plugin to do that, like my &lt;A href="https://ricaun.com/apploader/" target="_blank" rel="noopener"&gt;ricaun.AppLoader&lt;/A&gt; plugin for Revit.&lt;/P&gt;&lt;P&gt;&lt;div class="video-embed-center video-embed"&gt;&lt;iframe class="embedly-embed" src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F9BslI_JnV6Y%3Ffeature%3Doembed&amp;amp;display_name=YouTube&amp;amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D9BslI_JnV6Y&amp;amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F9BslI_JnV6Y%2Fhqdefault.jpg&amp;amp;type=text%2Fhtml&amp;amp;schema=youtube" width="200" height="112" scrolling="no" title="ricaun.AppLoader - English" frameborder="0" allow="autoplay; fullscreen; encrypted-media; picture-in-picture;" allowfullscreen="true"&gt;&lt;/iframe&gt;&lt;/div&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I already know a way to load/unload commands:&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;A href="https://github.com/ricaun-io/ricaun.AutoCAD.UI/blob/0.4.0/ricaun.AutoCAD.UI/Runtime/CommandUtils.cs" target="_blank" rel="noopener"&gt;CommandUtils.cs&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Would be easy to do I guess, AutoCAD is so much easier to work comparing with Revit plugins.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 12 Sep 2025 13:29:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13807970#M85749</guid>
      <dc:creator>ricaun</dc:creator>
      <dc:date>2025-09-12T13:29:38Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13808715#M85750</link>
      <description>&lt;P&gt;Perhaps it's a definition of terms issue.&lt;BR /&gt;to me :&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Hot Reload is&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;a feature in Visual Studio which can automatically re-compile and load in changes to your program &lt;EM&gt;while you are debugging&lt;/EM&gt;, without having to pause, or do a full rebuild.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Regards,&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 13 Sep 2025 00:20:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13808715#M85750</guid>
      <dc:creator>kerry_w_brown</dc:creator>
      <dc:date>2025-09-13T00:20:49Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13809274#M85752</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/529262"&gt;@kerry_w_brown&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;Perhaps it's a definition of terms issue.&lt;BR /&gt;to me :&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Hot Reload is&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;a feature in Visual Studio which can automatically re-compile and load in changes to your program &lt;EM&gt;while you are debugging&lt;/EM&gt;, without having to pause, or do a full rebuild.&lt;/STRONG&gt;&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Hot Reload works great in some situations, but is not gonna restart the&amp;nbsp;&lt;STRONG&gt;IExtensionApplication&lt;/STRONG&gt;, like&amp;nbsp;&lt;STRONG&gt;Terminate&lt;/STRONG&gt; and &lt;STRONG&gt;Initialize&lt;/STRONG&gt; again.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In Revit most at the time I don't use &lt;STRONG&gt;Debug,&lt;/STRONG&gt;&amp;nbsp;if I can 'reload' the addin application with Revit open I just build the project again and I have a new version running.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can always attach the Debug in Visual Studio latter using this:&amp;nbsp;&lt;A href="https://github.com/ricaun-io/RevitAddin.VisualStudioDebug/" target="_blank"&gt;https://github.com/ricaun-io/RevitAddin.VisualStudioDebug/&amp;nbsp;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyway technically is impossible/really hard to unlock a .net assembly that is been using by a windows application process, if the application loads the dll by default is lock until the application closes.&lt;/P&gt;</description>
      <pubDate>Sat, 13 Sep 2025 13:06:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13809274#M85752</guid>
      <dc:creator>ricaun</dc:creator>
      <dc:date>2025-09-13T13:06:35Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13817454#M85766</link>
      <description>&lt;P&gt;I am using a custom workaround to reload assemblies. I put all my code in a try-catch block, and in the catch I'm displaying the error message + stacktrace. I simply load the builded dll with NETLOAD in AutoCAD (without using the Visual Studio debugger) and run the command. If I get an error, it gives the error description and error line. Then I change the code, build the dll with a different name (I'm using a version number in the name) and load the new dll with NETLOAD. This overrides the old CommandMethod and I can test again. In this way there is no need to restart AutoCAD while testing. Only disadvantage is that you only get the error message+stacktrace, no further debugging information.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Sep 2025 07:18:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13817454#M85766</guid>
      <dc:creator>gleeuwdrent</dc:creator>
      <dc:date>2025-09-19T07:18:49Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822748#M85793</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3008387"&gt;@gleeuwdrent&lt;/a&gt;&amp;nbsp;this sounds like mine approach as well, I've setup acad.lsp to first copy .dll to a temporary location and netload it instead though, so that you can rebuild the original .dll without having to juggle names. After a few weeks of working with it I must say it's shown to be quite buggy, but it should be repairable in the future.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Sep 2025 22:24:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822748#M85793</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-23T22:24:47Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822785#M85794</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/16639190"&gt;@baleti3266&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3008387"&gt;@gleeuwdrent&lt;/a&gt;&amp;nbsp;this sounds like mine approach as well, I've setup acad.lsp to first copy .dll to a temporary location and netload it instead though, so that you can rebuild the original .dll without having to juggle names. After a few weeks of working with it I must say it's shown to be quite buggy, but it should be repairable in the future.&lt;/P&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;This trick (copying the dll to another location and/or renaming it) isn't really workable in any but the simplest scenarios.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problems with doing that are many. All previously-loaded copies of the assembly remain loaded, and the types in them are not equivalent. IOW, (assuming 'MyPlugIn01.dll' and 'MyPlugIn02.dll' are copies of the same file), 'MyClass' in MyPlugin01.dll is not the same class as 'MyClass' in MyPlugin02.dll. They are different assemblies with different types. So, if you use typeof() or GetType() somewhere you are likely going to have problems.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And then there is the problem of static (shared in VB) variables which have process-scope. That means each time you reference a static member in an assembly that was renamed and 'reloaded', you are referencing a different copy of that static member, which in most-cases, defeats the purpose of using static members, and also leads to bugs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, the 'trick' being discussed here and elsewhere, can actually become the source of numerous bugs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Sep 2025 23:19:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822785#M85794</guid>
      <dc:creator>ActivistInvestor</dc:creator>
      <dc:date>2025-09-23T23:19:23Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822845#M85795</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4476837"&gt;@ActivistInvestor&lt;/a&gt;&amp;nbsp;- given development of AutoCAD-related tools:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would you suggest someone properly debug a .NET (non-COM dependent, such as SSM API, etc) plugin?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When would you recommend debug launch vs process attach?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TIA, Cheers&lt;/P&gt;</description>
      <pubDate>Wed, 24 Sep 2025 01:04:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13822845#M85795</guid>
      <dc:creator>BlackBox_</dc:creator>
      <dc:date>2025-09-24T01:04:33Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13824292#M85804</link>
      <description>&lt;P&gt;noted, my current implementation is very buggy and the reasons you listed may be part of it, however I had successes using this method with revit api - a Release dll loaded on start for everyday use and Debug dll invoked through reflection for development. Do you think there is anything specific to autocad api that may be getting in the way? Because if there isn't I'm tempted to continue ironing bugs out until it works. Not sure how simple my needs are, usually it's just commands setting attributes, changing views, reading .dwgs across documents as separate commands.&lt;/P&gt;</description>
      <pubDate>Wed, 24 Sep 2025 20:19:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13824292#M85804</guid>
      <dc:creator>baleti3266</dc:creator>
      <dc:date>2025-09-24T20:19:51Z</dc:date>
    </item>
    <item>
      <title>Re: How do you deal with .net assembly locking (making changes without restarting autocad)?</title>
      <link>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13827237#M85814</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1206685"&gt;@BlackBox_&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4476837"&gt;@ActivistInvestor&lt;/a&gt;&amp;nbsp;- given development of AutoCAD-related tools:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would you suggest someone properly debug a .NET (non-COM dependent, such as SSM API, etc) plugin?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When would you recommend debug launch vs process attach?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I use both, but often just use Attach to Process because it's faster. I also test without the debugger (again because it's faster), but may come across something that I need to look at more-closely, and so I can just attach at any time for that.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Sep 2025 15:26:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/how-do-you-deal-with-net-assembly-locking-making-changes-without/m-p/13827237#M85814</guid>
      <dc:creator>ActivistInvestor</dc:creator>
      <dc:date>2025-09-26T15:26:21Z</dc:date>
    </item>
  </channel>
</rss>

