<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Zugriffsverletzung bei statisch eingebundener DLL]]></title><description><![CDATA[<p>Moin zusammen,</p>
<p>ic hab folgendes Problem - naja eigentlich sind eher zwei, aber das eine ergab sich aus dem anderen.<br />
Ich habe mit BCB 5, auf XP eine dll erzeugt, die mehrere Formulare enthält. Diese dll lässt sich in einem anderen Programm unter XP ohne Probleme über #pragma link &quot;actions.dll&quot; einbinden. Läuft auch alles super. Wenn ich das Programm jedoch auf NT laufen lasse, dann kommt die Meldung, &quot;Zugriffsverletzung bei Adresse &lt;xy&gt; im Modul 'actions.dll'. Schreiben von Adresse 060.&quot;</p>
<p>Was mir noch aufgefallen ist, wenn ich die DLL im Debug-Modus kompiliere lässt sie sich ohne Probleme unter XP einbinden. Wenn ich sie allerding im Endgültig-Modus kompiliere, dann kommt wieder &quot;Zugriffsverletzung...&quot;</p>
<p>Weiss jemand Rat dazu?</p>
<p>p.s. hab grad rausgefunden, wenn ich die Codeoptimierung abschalte, lässt sich<br />
die DLL auch im &quot;Endgültig&quot;-Modus kompilieren...<br />
Gruss, Sven</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/93740/zugriffsverletzung-bei-statisch-eingebundener-dll</link><generator>RSS for Node</generator><lastBuildDate>Thu, 09 Jul 2026 13:32:57 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/93740.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 02 Dec 2004 08:22:38 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Zugriffsverletzung bei statisch eingebundener DLL on Thu, 02 Dec 2004 08:26:36 GMT]]></title><description><![CDATA[<p>Moin zusammen,</p>
<p>ic hab folgendes Problem - naja eigentlich sind eher zwei, aber das eine ergab sich aus dem anderen.<br />
Ich habe mit BCB 5, auf XP eine dll erzeugt, die mehrere Formulare enthält. Diese dll lässt sich in einem anderen Programm unter XP ohne Probleme über #pragma link &quot;actions.dll&quot; einbinden. Läuft auch alles super. Wenn ich das Programm jedoch auf NT laufen lasse, dann kommt die Meldung, &quot;Zugriffsverletzung bei Adresse &lt;xy&gt; im Modul 'actions.dll'. Schreiben von Adresse 060.&quot;</p>
<p>Was mir noch aufgefallen ist, wenn ich die DLL im Debug-Modus kompiliere lässt sie sich ohne Probleme unter XP einbinden. Wenn ich sie allerding im Endgültig-Modus kompiliere, dann kommt wieder &quot;Zugriffsverletzung...&quot;</p>
<p>Weiss jemand Rat dazu?</p>
<p>p.s. hab grad rausgefunden, wenn ich die Codeoptimierung abschalte, lässt sich<br />
die DLL auch im &quot;Endgültig&quot;-Modus kompilieren...<br />
Gruss, Sven</p>
]]></description><link>https://www.c-plusplus.net/forum/post/664188</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/664188</guid><dc:creator><![CDATA[Sven_S]]></dc:creator><pubDate>Thu, 02 Dec 2004 08:26:36 GMT</pubDate></item><item><title><![CDATA[Reply to Zugriffsverletzung bei statisch eingebundener DLL on Thu, 02 Dec 2004 11:21:08 GMT]]></title><description><![CDATA[<p>Problem gefunden:</p>
<p>der Fehler liegt nich am Einbinden der dll, sondern an einem Funktionsaufruf, der durchgeführt wird. Und zwar hab ich in der dll eine Funktion, der ich einen Zeiger auf ein TreeView übergebe, und diese Funktion füllt den TreeView aus. anscheinend kommts da zu Fehlern bei NT. Nur weshalb funzt das unter XP?</p>
<p>Gruss, Sven</p>
<pre><code class="language-cpp">extern &quot;C&quot; __declspec(dllexport) __stdcall void LoadActionTree(TTreeNodes* Items,TImageList* IList,TComponent* Owner)
{
  TTreeNode *Node=NULL;
  TForm_Action_Tree* TreeForm=new TForm_Action_Tree(Owner);
  TIcon *Icon;
  for (int i=0;i&lt;TreeForm-&gt;ImageList1-&gt;Count;i++)
  {
    TreeForm-&gt;ImageList1-&gt;GetIcon(i,Icon);
    IList-&gt;AddIcon(Icon);
  }

  Items-&gt;Clear();
  for (int i=0;i&lt;TreeForm-&gt;TreeView1-&gt;Items-&gt;Count;i++)
  {
    if (TreeForm-&gt;TreeView1-&gt;Items-&gt;Item[i]-&gt;HasChildren)
    {
      Items-&gt;Add(Node,TreeForm-&gt;TreeView1-&gt;Items-&gt;Item[i]-&gt;Text);
      Node=Items-&gt;Item[i];
    }else Items-&gt;AddChild(Node,TreeForm-&gt;TreeView1-&gt;Items-&gt;Item[i]-&gt;Text);
    Items-&gt;Item[i]-&gt;ImageIndex=TreeForm-&gt;TreeView1-&gt;Items-&gt;Item[i]-&gt;ImageIndex;
    Items-&gt;Item[i]-&gt;SelectedIndex=Items-&gt;Item[i]-&gt;ImageIndex;
  }
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/664336</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/664336</guid><dc:creator><![CDATA[Sven_S]]></dc:creator><pubDate>Thu, 02 Dec 2004 11:21:08 GMT</pubDate></item></channel></rss>