<?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[dll aus in dll mittels loadlib einbinden]]></title><description><![CDATA[<p>Hallo,</p>
<p>ich versuche aus einer dll(DLLA) die von einer exe geladen wurde,eine andere dll(DLLB) zu laden. Die DLLA kann einwandfrei geldaden werden. Danach rue ich eine Funktion der DLLA auf und will dort nun DLLB laden. Doch sobald ich loadlibrary aufrufe bekomme ich eine Exception (Access Violation). Was mache ich hier falsch, oder ist dies nicht möglich <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f615.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--confused_face"
      title=":confused:"
      alt="😕"
    /> ?</p>
<p>Hier der Code in der Dll:</p>
<pre><code>int _stdcall Algo(LPCSTR lpDllFileName)
{
	int x = 0;

	// Dynamisch eine DLL Laden
	m_LibA = LoadLibrary(lpDllFileName);

	// Funktionspointer holen
	if( m_LibA == NULL )
	{
		//printf(&quot;Could not load the DLL!\r\n&quot;);
	}
	else
	{
		lpGetNumberA = (LPGETNUMBERA)GetProcAddress(m_LibA, &quot;sum&quot;);
	}

	// Funktion aufrufen
	if( lpGetNumberA != 0 )
		x = lpGetNumberA( 14, 5 );

	// DLL wieder freigeben
	FreeLibrary(m_LibA);
	lpGetNumberA = 0;

	return x;
}
</code></pre>
<p>Lg<br />
Steve</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/203084/dll-aus-in-dll-mittels-loadlib-einbinden</link><generator>RSS for Node</generator><lastBuildDate>Sun, 05 Apr 2026 20:41:24 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/203084.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 18 Jan 2008 15:45:00 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to dll aus in dll mittels loadlib einbinden on Fri, 18 Jan 2008 15:45:00 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>ich versuche aus einer dll(DLLA) die von einer exe geladen wurde,eine andere dll(DLLB) zu laden. Die DLLA kann einwandfrei geldaden werden. Danach rue ich eine Funktion der DLLA auf und will dort nun DLLB laden. Doch sobald ich loadlibrary aufrufe bekomme ich eine Exception (Access Violation). Was mache ich hier falsch, oder ist dies nicht möglich <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f615.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--confused_face"
      title=":confused:"
      alt="😕"
    /> ?</p>
<p>Hier der Code in der Dll:</p>
<pre><code>int _stdcall Algo(LPCSTR lpDllFileName)
{
	int x = 0;

	// Dynamisch eine DLL Laden
	m_LibA = LoadLibrary(lpDllFileName);

	// Funktionspointer holen
	if( m_LibA == NULL )
	{
		//printf(&quot;Could not load the DLL!\r\n&quot;);
	}
	else
	{
		lpGetNumberA = (LPGETNUMBERA)GetProcAddress(m_LibA, &quot;sum&quot;);
	}

	// Funktion aufrufen
	if( lpGetNumberA != 0 )
		x = lpGetNumberA( 14, 5 );

	// DLL wieder freigeben
	FreeLibrary(m_LibA);
	lpGetNumberA = 0;

	return x;
}
</code></pre>
<p>Lg<br />
Steve</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1439124</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1439124</guid><dc:creator><![CDATA[steve2704]]></dc:creator><pubDate>Fri, 18 Jan 2008 15:45:00 GMT</pubDate></item><item><title><![CDATA[Reply to dll aus in dll mittels loadlib einbinden on Mon, 21 Jan 2008 10:46:33 GMT]]></title><description><![CDATA[<p>Für die dies interressiert:</p>
<p>Hab das Problem gelöst!<br />
Bei meinen Dlls habe ich Debug- und Releaseversionen gemischt, was dann diese Access Violation im VC6 ausgelöst hat....</p>
<p>LG<br />
Steve</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1440459</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1440459</guid><dc:creator><![CDATA[steve2704]]></dc:creator><pubDate>Mon, 21 Jan 2008 10:46:33 GMT</pubDate></item></channel></rss>