<?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: netload command in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/12234770#M15476</link>
    <description>&lt;P&gt;&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/1084052"&gt;@RomuloMagalhaes&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi, i'm having the same trouble here.&lt;/P&gt;&lt;P&gt;I have a DLL with several routines that depends on a PG database.&lt;/P&gt;&lt;P&gt;I used to integrate npgsql.dll as a standalone dependency and this worked well with the plugin autoload (LoadOnAutoCADStartup= true).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to migrate our library to AUTOCAD MAP 2024 (VS2022 and .NET framework 4.8) but the Npgsql is now interegated as a nuget package only.&lt;/P&gt;&lt;P&gt;So I dowloaded all the dependencies (very much some system DLLs), and It still works well when I run NetLOAD manually.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The issue is when I try to autoload on startup my plugin. It loads well and I have no error. But when I use a command that requires the PG DB and npgsql.DLL dependency, I get an error saying :&amp;nbsp;&lt;/P&gt;&lt;P&gt;"Message d'erreur : Une exception a été levée par l'initialiseur de type pour 'Npgsql.TypeMapping.BuiltInTypeHandlerResolver'. "&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All the dependencies are in the Contents folder and a manual "NETLOAD" + pick manually my DLL works well without error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What am I missing ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1084052"&gt;@RomuloMagalhaes&lt;/a&gt;&amp;nbsp;have you finally find an answer to your question ?&lt;/P&gt;</description>
    <pubDate>Tue, 12 Sep 2023 14:00:35 GMT</pubDate>
    <dc:creator>APRR_SITE_DIJON</dc:creator>
    <dc:date>2023-09-12T14:00:35Z</dc:date>
    <item>
      <title>netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568350#M15464</link>
      <description>&lt;P&gt;I want to load a DLL without selecting path in explorer.&lt;/P&gt;&lt;P&gt;I tried passing arguments like "netload" "D:\addin1.dll" in command prompt, I tried similarly on macro of a button command.&lt;/P&gt;&lt;P&gt;Is their a way to Load DLL automatically given its path?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Our actual Requirement:&lt;/P&gt;&lt;P&gt;We don't want to load DLL in every session automatically. We want to load it when user clicks a button.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 05:37:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568350#M15464</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-08-24T05:37:20Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568683#M15465</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;You can enter a LISP expression directly at command line:&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;(command "netload" "D:\\addin1.dll")&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp; &lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 08:08:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568683#M15465</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2021-08-24T08:08:09Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568864#M15466</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/109424"&gt;@_gile&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much.&amp;nbsp;It's Working but it's not meeting our requirement, I need a macro also working like that not just lisp command.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 09:30:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568864#M15466</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-08-24T09:30:46Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568920#M15467</link>
      <description>&lt;P&gt;A macro can contain LISP expressions:&lt;/P&gt;
&lt;LI-CODE lang="general"&gt;^C^C(command "netload" "D:\\addin1.dll");&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 24 Aug 2021 09:54:44 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10568920#M15467</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2021-08-24T09:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10569959#M15468</link>
      <description>&lt;P&gt;Its working but i need to keep the dll file in same directory. Because when i do D:\%path it is getting terminated on :(colon)&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 15:43:45 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10569959#M15468</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-08-24T15:43:45Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570000#M15469</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous&amp;nbsp; a écrit&amp;nbsp;:&lt;BR /&gt;
&lt;P&gt;Its working but i need to keep the dll file in same directory. Because when i do D:\%path it is getting terminated on :(colon)&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Sorry I do not understand what you mean.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 15:52:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570000#M15469</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2021-08-24T15:52:53Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570377#M15470</link>
      <description>&lt;P&gt;Are you using &lt;A href="https://knowledge.autodesk.com/support/autocad/learn-explore/caas/sfdcarticles/sfdcarticles/Automatically-load-AutoLISP-routines.html" target="_blank" rel="noopener"&gt;&lt;EM&gt;either "/" or "\\" as path delimiters&lt;/EM&gt;&lt;/A&gt;? It seems you are always writing a single "\", hence not reading the rest of the path.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 18:27:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570377#M15470</guid>
      <dc:creator>miguelmachadoecosta</dc:creator>
      <dc:date>2021-08-24T18:27:46Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570785#M15471</link>
      <description>&lt;P&gt;Not directly what you're looking for, but should serve the purpose well: look into demand loading using the registry.&amp;nbsp; Set the load flag to load on command, with the command being called by the specified button.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From your other comments, it's unclear as where you are trying to load from, or how you are specifying that folder location.&amp;nbsp; If you are trying to load directly from the root of a local drive that's... somewhere between 'interesting' and 'not a great idea'.&amp;nbsp; You should know *exactly* where the DLL will be located on users computers, and it should be the same on each of them.&amp;nbsp; Preferably this would be a naturally secure location such as a subfolder under ProgramFiles, although not necessarily in an Autodesk/AutoCAD provided one.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you are trying to load a DLL from anywhere other than the computer's system drive, then you may be running into security restrictions (which is a good thing, as it protects against malicious code).&lt;/P&gt;</description>
      <pubDate>Tue, 24 Aug 2021 21:13:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/10570785#M15471</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2021-08-24T21:13:11Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11391306#M15472</link>
      <description>&lt;P&gt;I have :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Folder: "&lt;STRONG&gt;C:\MyFolder&lt;/STRONG&gt;", that&amp;nbsp;is part of &lt;EM&gt;TRUSTED PATHS&lt;/EM&gt; on AUTOCAD.&lt;/P&gt;&lt;P&gt;Inside "&lt;STRONG&gt;c:\MyFolder&lt;/STRONG&gt;", I have:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;"&lt;STRONG&gt;MYADDIN.DLL&lt;/STRONG&gt;" : main DLL of my project,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;that have dependencies, for example (all managed .net dlls):&lt;/P&gt;&lt;P&gt;&lt;EM&gt;. DEPENDENCE1.DLL&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;. DEPENDENCE2.DLL&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I type "&lt;STRONG&gt;NETLOAD&lt;/STRONG&gt;" via command line, and select&amp;nbsp; '&lt;STRONG&gt;MYADDIN.DLL&lt;/STRONG&gt;'&amp;nbsp; when form is opened, all is loaded ok, and all commands that are inside this DLL are executed normally.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;but...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I use :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(COMMAND "NETLOAD" "c:\\MyFolder\\MYADDIN.dll" )&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I receive, in determinated command, that depends on, for example, of "&lt;STRONG&gt;DEPENDENCE1.DLL&lt;/STRONG&gt;" a exception, like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;' System.TypeInitializationException: The type initializer for 'modulexxxxxx' threw an exception.&amp;nbsp;---&amp;gt; System.IO.FileNotFoundException: Could not load file or assembly '&lt;STRONG&gt;DEPENDENCE1&lt;/STRONG&gt;, Version=x.x.x.x, Culture=neutral,&lt;BR /&gt;PublicKeyToken=1488e028ca7ab535'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I don't understand which difference between...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;_NETLOAD&lt;/STRONG&gt; + enter + select file &lt;STRONG&gt;MYADDIN.DLL &lt;/STRONG&gt;on form &lt;EM&gt;Choose .NET Assemply&lt;/EM&gt; ===&amp;gt; ALL OK, fine.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;and...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(COMMAND "NETLOAD"&amp;nbsp; "C:\\MyFolder\\MYADDIN.DLL")&lt;/STRONG&gt; ==&amp;gt; Launched exception : Not found dll dependence file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anybody can help me?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My Environment:&lt;/P&gt;&lt;P&gt;. Windows 10 64 bits : original;&lt;/P&gt;&lt;P&gt;. AutoCAD 2017 64 bits : original;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Aug 2022 19:34:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11391306#M15472</guid>
      <dc:creator>RomuloMagalhaes</dc:creator>
      <dc:date>2022-08-30T19:34:29Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11392049#M15473</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1084052"&gt;@RomuloMagalhaes&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Did you try to add "&lt;STRONG&gt;C:\MyFolder&lt;/STRONG&gt;" to the AutoCAD search path or to set &lt;A href="https://knowledge.autodesk.com/support/autocad/learn-explore/caas/CloudHelp/cloudhelp/2016/ENU/AutoCAD-Core/files/GUID-1E582989-79A5-4B88-A9C2-8826E3FF9430-htm.html" target="_blank" rel="noopener"&gt;LEGACYCODESEARCH&lt;/A&gt; system variable to 1.&lt;/P&gt;
&lt;P&gt;You can read &lt;A href="https://help.autodesk.com/view/OARX/2023/ENU/?guid=GUID-25616676-EFF2-4060-A06F-19112622A78B" target="_blank" rel="noopener"&gt;this topic&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Wed, 31 Aug 2022 05:25:15 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11392049#M15473</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2022-08-31T05:25:15Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11393857#M15474</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/109424"&gt;@_gile&lt;/a&gt;&amp;nbsp;THANK YOU very much for your attention.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1) Did you try to add "C:\MyFolder" to the AutoCAD search path?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;YES, previous added.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2) Set&amp;nbsp;LEGACYCODESEARCH&amp;nbsp;system variable to 1?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;YES, too.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;3) You can read&amp;nbsp;this topic&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Yes, I just read this topic, that contains &lt;STRONG&gt;(COMMAND "NETLOAD" "my.dll")&lt;/STRONG&gt; too! ==&amp;gt; my problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to discover how and why :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;_NETLOAD&lt;/STRONG&gt; + select my.dll on form&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;is different of:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(COMMAND "NETLOAD" "my.dll")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Because the &lt;EM&gt;SAME FOLDER, SAME ENVIRONMENT VARIABLES&lt;/EM&gt;, and &lt;EM&gt;SAME DLL&lt;/EM&gt;, with &lt;STRONG&gt;different behavior&lt;/STRONG&gt;, on the SAME AUTOCAD.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Aug 2022 20:22:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11393857#M15474</guid>
      <dc:creator>RomuloMagalhaes</dc:creator>
      <dc:date>2022-08-31T20:22:02Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11393970#M15475</link>
      <description>&lt;P&gt;Are the Dependance1.dll and Dependance2.dll in the same "&lt;STRONG&gt;C:\MyFolder&lt;/STRONG&gt;" as the plugin one?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Aug 2022 21:30:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/11393970#M15475</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2022-08-31T21:30:13Z</dc:date>
    </item>
    <item>
      <title>Re: netload command</title>
      <link>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/12234770#M15476</link>
      <description>&lt;P&gt;&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/1084052"&gt;@RomuloMagalhaes&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi, i'm having the same trouble here.&lt;/P&gt;&lt;P&gt;I have a DLL with several routines that depends on a PG database.&lt;/P&gt;&lt;P&gt;I used to integrate npgsql.dll as a standalone dependency and this worked well with the plugin autoload (LoadOnAutoCADStartup= true).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to migrate our library to AUTOCAD MAP 2024 (VS2022 and .NET framework 4.8) but the Npgsql is now interegated as a nuget package only.&lt;/P&gt;&lt;P&gt;So I dowloaded all the dependencies (very much some system DLLs), and It still works well when I run NetLOAD manually.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The issue is when I try to autoload on startup my plugin. It loads well and I have no error. But when I use a command that requires the PG DB and npgsql.DLL dependency, I get an error saying :&amp;nbsp;&lt;/P&gt;&lt;P&gt;"Message d'erreur : Une exception a été levée par l'initialiseur de type pour 'Npgsql.TypeMapping.BuiltInTypeHandlerResolver'. "&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;All the dependencies are in the Contents folder and a manual "NETLOAD" + pick manually my DLL works well without error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What am I missing ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1084052"&gt;@RomuloMagalhaes&lt;/a&gt;&amp;nbsp;have you finally find an answer to your question ?&lt;/P&gt;</description>
      <pubDate>Tue, 12 Sep 2023 14:00:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/netload-command/m-p/12234770#M15476</guid>
      <dc:creator>APRR_SITE_DIJON</dc:creator>
      <dc:date>2023-09-12T14:00:35Z</dc:date>
    </item>
  </channel>
</rss>

