<?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: loading the dll through arx application in ObjectARX Forum</title>
    <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082272#M6427</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1937895"&gt;@moogalm&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/481027"&gt;@Alexander.Rivilis&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I feel the there is mismatch in calling convention, instead of _stdcall, it should have _cdecl, I'm not sure if this is giving a compiler error for you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__stdcall &lt;/FONT&gt;LoadManagedDll(ACHAR const *path);
static int ads_netload(void)
{&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;img id="manhappy" class="emoticon emoticon-manhappy" src="https://forums.autodesk.com/i/smilies/16x16_man-happy.png" alt="Man Happy" title="Man Happy" /&gt;&lt;/P&gt;
&lt;P&gt;The truth is somewhere in the middle:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;AutoCAD 2019 x86:&lt;/P&gt;
&lt;PRE&gt;?LoadManagedDll@@YG?AW4ErrorStatus@Acad@@PB_W@Z (enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__stdcall&lt;/FONT&gt; LoadManagedDll(wchar_t const *))&lt;/PRE&gt;
&lt;P&gt;AutoCAD 2019 x64:&lt;/P&gt;
&lt;PRE&gt;?LoadManagedDll@@YA?AW4ErrorStatus@Acad@@PEB_W@Z (enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__cdecl&lt;/FONT&gt; LoadManagedDll(wchar_t const *))&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 21 Jun 2018 09:19:10 GMT</pubDate>
    <dc:creator>Alexander.Rivilis</dc:creator>
    <dc:date>2018-06-21T09:19:10Z</dc:date>
    <item>
      <title>loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082057#M6424</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I am trying to load the dll through arx application,&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;bool bLoads = acrxLoadModule(pathLvPty, true);&lt;/PRE&gt;&lt;P&gt;there are two dll which is being loaded in that one is successfully loaded, while other gives the error message as:&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;acrxGetApiVersion not found in e:\waseef\property_isolate.dll&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;Make sure the app links with rxapi.lib and export the symbol.AcRxDynamicLinker failed to load 'e:\waseef\property_isolate.dll&lt;/FONT&gt;&lt;BR /&gt;Can anyone please advice, where I need to change to load the dll successfully.&lt;BR /&gt;&lt;BR /&gt;Thanks&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 07:24:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082057#M6424</guid>
      <dc:creator>waseefur.rahman</dc:creator>
      <dc:date>2018-06-21T07:24:35Z</dc:date>
    </item>
    <item>
      <title>Re: loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082085#M6425</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4333282"&gt;@waseefur.rahman&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I am trying to load the dll through arx application,&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE&gt;bool bLoads = acrxLoadModule(pathLvPty, true);&lt;/PRE&gt;
&lt;P&gt;there are two dll which is being loaded in that one is successfully loaded, while other gives the error message as:&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;acrxGetApiVersion not found in e:\waseef\property_isolate.dll&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#ff0000"&gt;Make sure the app links with rxapi.lib and export the symbol.AcRxDynamicLinker failed to load 'e:\waseef\property_isolate.dll&lt;/FONT&gt;&lt;BR /&gt;Can anyone please advice, where I need to change to load the dll successfully.&lt;BR /&gt;&lt;BR /&gt;Thanks&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Both dll's are arx/dbx files? If dll is mixed/managed application you have to load it such as:&lt;/P&gt;
&lt;P&gt;1) LoadLibrary()&lt;BR /&gt;2) Also acdbmgd.lib export function LoadManagedDll:&lt;BR /&gt;enum Acad::ErrorStatus __stdcall LoadManagedDll(ACHAR const *path);&lt;BR /&gt;Sample:&lt;/P&gt;
&lt;PRE&gt;enum Acad::ErrorStatus __stdcall LoadManagedDll(ACHAR const *path);
static int ads_netload(void)
{
  struct resbuf *pArgs = acedGetArgs () ;
  acedRetNil();
  if (pArgs &amp;amp;&amp;amp; pArgs-&amp;gt;restype == RTSTR) {
  Acad::ErrorStatus es = LoadManagedDll(pArgs-&amp;gt;resval.rstring);
  if (es != Acad::eOk) {
     acutPrintf(_T("\nLoadManagedDll(\"%s\")=%s"),
        pArgs-&amp;gt;resval.rstring,acadErrorStatusText(es));
  } else 
    acedRetStr(pArgs-&amp;gt;resval.rstring);
  } 
  return (RSRSLT) ;
}&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 07:39:13 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082085#M6425</guid>
      <dc:creator>Alexander.Rivilis</dc:creator>
      <dc:date>2018-06-21T07:39:13Z</dc:date>
    </item>
    <item>
      <title>Re: loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082255#M6426</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/481027"&gt;@Alexander.Rivilis&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I feel the there is mismatch in calling convention, instead of _stdcall, it should have _cdecl, I'm not sure if this is giving a compiler error for you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__stdcall &lt;/FONT&gt;LoadManagedDll(ACHAR const *path);
static int ads_netload(void)
{&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 09:04:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082255#M6426</guid>
      <dc:creator>moogalm</dc:creator>
      <dc:date>2018-06-21T09:04:37Z</dc:date>
    </item>
    <item>
      <title>Re: loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082272#M6427</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1937895"&gt;@moogalm&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/481027"&gt;@Alexander.Rivilis&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I feel the there is mismatch in calling convention, instead of _stdcall, it should have _cdecl, I'm not sure if this is giving a compiler error for you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__stdcall &lt;/FONT&gt;LoadManagedDll(ACHAR const *path);
static int ads_netload(void)
{&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;img id="manhappy" class="emoticon emoticon-manhappy" src="https://forums.autodesk.com/i/smilies/16x16_man-happy.png" alt="Man Happy" title="Man Happy" /&gt;&lt;/P&gt;
&lt;P&gt;The truth is somewhere in the middle:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;AutoCAD 2019 x86:&lt;/P&gt;
&lt;PRE&gt;?LoadManagedDll@@YG?AW4ErrorStatus@Acad@@PB_W@Z (enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__stdcall&lt;/FONT&gt; LoadManagedDll(wchar_t const *))&lt;/PRE&gt;
&lt;P&gt;AutoCAD 2019 x64:&lt;/P&gt;
&lt;PRE&gt;?LoadManagedDll@@YA?AW4ErrorStatus@Acad@@PEB_W@Z (enum Acad::ErrorStatus &lt;FONT color="#FF6600"&gt;__cdecl&lt;/FONT&gt; LoadManagedDll(wchar_t const *))&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 09:19:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082272#M6427</guid>
      <dc:creator>Alexander.Rivilis</dc:creator>
      <dc:date>2018-06-21T09:19:10Z</dc:date>
    </item>
    <item>
      <title>Re: loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082642#M6428</link>
      <description>&lt;P&gt;Hi Rivilis,&lt;BR /&gt;&lt;BR /&gt;As when I add the Reference, it get some other error in my solution,&lt;BR /&gt;Could it be possible to load the Dll in command prompt itself,&lt;BR /&gt;&lt;BR /&gt;I have done in .net to load the dll in command prompt itself, below is the coding.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;ThisDrawing.SendCommand("FILEDIA" + vbCr &amp;amp; "0" + vbCr)
ThisDrawing.SendCommand("NETLOAD" + vbCr + "E:\waseef\property_isolation.dll" + vbCr)
ThisDrawing.SendCommand("FILEDIA" + vbCr &amp;amp; "1" + vbCr)&lt;/PRE&gt;&lt;P&gt;could you please advice how to achive the similar in C++.&lt;BR /&gt;&lt;BR /&gt;Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 12:42:22 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082642#M6428</guid>
      <dc:creator>waseefur.rahman</dc:creator>
      <dc:date>2018-06-21T12:42:22Z</dc:date>
    </item>
    <item>
      <title>Re: loading the dll through arx application</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082676#M6429</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/4333282"&gt;@waseefur.rahman&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi Rivilis,&lt;BR /&gt;&lt;BR /&gt;As when I add the Reference, it get some other error in my solution,&lt;BR /&gt;Could it be possible to load the Dll in command prompt itself,&lt;BR /&gt;&lt;BR /&gt;I have done in .net to load the dll in command prompt itself, below is the coding.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE&gt;ThisDrawing.SendCommand("FILEDIA" + vbCr &amp;amp; "0" + vbCr)
ThisDrawing.SendCommand("NETLOAD" + vbCr + "E:\waseef\property_isolation.dll" + vbCr)
ThisDrawing.SendCommand("FILEDIA" + vbCr &amp;amp; "1" + vbCr)&lt;/PRE&gt;
&lt;P&gt;could you please advice how to achive the similar in C++.&lt;BR /&gt;&lt;BR /&gt;Thanks&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;LoadManagedDll(L"E:\\waseef\\property_isolation.dll")&lt;/PRE&gt;
&lt;P&gt;1. You have to insert definition of function LoadManagedDll as I posted above&lt;/P&gt;
&lt;P&gt;2. You have to link with acdbmgd.lib&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Jun 2018 12:51:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/loading-the-dll-through-arx-application/m-p/8082676#M6429</guid>
      <dc:creator>Alexander.Rivilis</dc:creator>
      <dc:date>2018-06-21T12:51:02Z</dc:date>
    </item>
  </channel>
</rss>

