<?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[&amp;quot;error LNK2019: Verweis auf nicht aufgelöstes externes Symbol&amp;quot;]]></title><description><![CDATA[<p>Hi <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
<p>Ich versuche derzeit eine Function in einen größeren c++ code zu integrieren. Den kompletten zu posten wäre also schonmal nicht möglich^^</p>
<p>Hier mal die beiden Functionen um die es sich handelt:</p>
<blockquote>
<p>---------------------------------------------------------<br />
int luaUnit_GetGMRank(lua_State * L, Unit * ptr)<br />
{<br />
if(!ptr)<br />
return 0;</p>
<p>switch(ptr-&gt;GetTypeId())<br />
{<br />
case TYPEID_PLAYER:<br />
const char *plName = ((Player*)ptr)-&gt;GetName();<br />
const char *GMRank = ((Player*)ptr)-&gt;GetGMRank(plName); //&lt;-- Denke mal hier tritt der, unten genannte, Fehler auf<br />
lua_pushstring(L,GMRank);<br />
break;<br />
}</p>
<p>return 1;<br />
}<br />
------------------------------------------------------------------------------<br />
------------------------------------------------------------------------------<br />
const char *GetGMRank(const char *plName)<br />
{<br />
QueryResult * result1 = CharacterDatabase.Query(&quot;SELECT * FROM characters WHERE name = plName&quot;);<br />
int acctnr = result1-&gt;Fetch()[2].GetInt8();</p>
<p>QueryResult * result = CharacterDatabase.Query(&quot;SELECT * FROM accounts WHERE acct = acctnr&quot;);<br />
const char *acct = result-&gt;Fetch()[1].GetString();</p>
<p>delete acctnr;<br />
return acct;<br />
}<br />
--------------------------------------------------------------------------------</p>
</blockquote>
<p>Folgender Fehler tritt dabei auf:</p>
<blockquote>
<p>error LNK2019: Verweis auf nicht aufgelöstes externes Symbol &quot;&quot;__declspec(dllimport) public: char const * __thiscall Player::GetGMRank(char const *)&quot; (__imp_?GetGMRank@Player@@QAEPBDPBD@Z)&quot; in Funktion &quot;&quot;int __cdecl luaUnit_GetGMRank(struct lua_State *,class Unit *)&quot; (?luaUnit_GetGMRank@@YAHPAUlua_State@@PAVUnit@@@Z)&quot;.<br />
2&gt;../../../bin/release/script_bin/LUAScripting.dll : fatal error LNK1120: 1 nicht aufgelöste externe Verweise.</p>
</blockquote>
<p>Ich habe schon zich mal gegooglet und alles probiert was mir einfällt, aber ich bekomm es einfach nicht auf die Reihe ^^ Ich hoffe ihr könnt mir helfen. Oder zumindest paar Vermutungen anstellen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
<p>Danke schonmal im vorraus</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/222175/quot-error-lnk2019-verweis-auf-nicht-aufgelöstes-externes-symbol-quot</link><generator>RSS for Node</generator><lastBuildDate>Mon, 05 Oct 2026 11:03:15 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/222175.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 08 Sep 2008 19:51:11 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to &amp;quot;error LNK2019: Verweis auf nicht aufgelöstes externes Symbol&amp;quot; on Mon, 08 Sep 2008 19:51:11 GMT]]></title><description><![CDATA[<p>Hi <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
<p>Ich versuche derzeit eine Function in einen größeren c++ code zu integrieren. Den kompletten zu posten wäre also schonmal nicht möglich^^</p>
<p>Hier mal die beiden Functionen um die es sich handelt:</p>
<blockquote>
<p>---------------------------------------------------------<br />
int luaUnit_GetGMRank(lua_State * L, Unit * ptr)<br />
{<br />
if(!ptr)<br />
return 0;</p>
<p>switch(ptr-&gt;GetTypeId())<br />
{<br />
case TYPEID_PLAYER:<br />
const char *plName = ((Player*)ptr)-&gt;GetName();<br />
const char *GMRank = ((Player*)ptr)-&gt;GetGMRank(plName); //&lt;-- Denke mal hier tritt der, unten genannte, Fehler auf<br />
lua_pushstring(L,GMRank);<br />
break;<br />
}</p>
<p>return 1;<br />
}<br />
------------------------------------------------------------------------------<br />
------------------------------------------------------------------------------<br />
const char *GetGMRank(const char *plName)<br />
{<br />
QueryResult * result1 = CharacterDatabase.Query(&quot;SELECT * FROM characters WHERE name = plName&quot;);<br />
int acctnr = result1-&gt;Fetch()[2].GetInt8();</p>
<p>QueryResult * result = CharacterDatabase.Query(&quot;SELECT * FROM accounts WHERE acct = acctnr&quot;);<br />
const char *acct = result-&gt;Fetch()[1].GetString();</p>
<p>delete acctnr;<br />
return acct;<br />
}<br />
--------------------------------------------------------------------------------</p>
</blockquote>
<p>Folgender Fehler tritt dabei auf:</p>
<blockquote>
<p>error LNK2019: Verweis auf nicht aufgelöstes externes Symbol &quot;&quot;__declspec(dllimport) public: char const * __thiscall Player::GetGMRank(char const *)&quot; (__imp_?GetGMRank@Player@@QAEPBDPBD@Z)&quot; in Funktion &quot;&quot;int __cdecl luaUnit_GetGMRank(struct lua_State *,class Unit *)&quot; (?luaUnit_GetGMRank@@YAHPAUlua_State@@PAVUnit@@@Z)&quot;.<br />
2&gt;../../../bin/release/script_bin/LUAScripting.dll : fatal error LNK1120: 1 nicht aufgelöste externe Verweise.</p>
</blockquote>
<p>Ich habe schon zich mal gegooglet und alles probiert was mir einfällt, aber ich bekomm es einfach nicht auf die Reihe ^^ Ich hoffe ihr könnt mir helfen. Oder zumindest paar Vermutungen anstellen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
<p>Danke schonmal im vorraus</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1578863</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1578863</guid><dc:creator><![CDATA[Egleria]]></dc:creator><pubDate>Mon, 08 Sep 2008 19:51:11 GMT</pubDate></item><item><title><![CDATA[Reply to &amp;quot;error LNK2019: Verweis auf nicht aufgelöstes externes Symbol&amp;quot; on Mon, 08 Sep 2008 20:02:26 GMT]]></title><description><![CDATA[<p>kann es sein dass du die methode</p>
<p>char* Player::GetGMRank(char const*)</p>
<p>nicht deklariert oder definiert hast?<br />
oder falsch hast?</p>
<p>/edit: ja du musst vor GetGMRank noch ein Player:: setzen...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1578868</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1578868</guid><dc:creator><![CDATA[Skym0sh0]]></dc:creator><pubDate>Mon, 08 Sep 2008 20:02:26 GMT</pubDate></item><item><title><![CDATA[Reply to &amp;quot;error LNK2019: Verweis auf nicht aufgelöstes externes Symbol&amp;quot; on Mon, 08 Sep 2008 20:09:29 GMT]]></title><description><![CDATA[<p>Boah du bist mein Held ey!!</p>
<p>Manchmal sieht man echt den Wald vor Bäumen nicht. 5 STunden sitzt ich nun schon an diesen Fehler und ich Depp sehs nicht, dass ich sowas triviales vergessen habe... Na ja zum Glück gibs ja Leute wie dich, die einen drauf aufmerksam machen^^</p>
<p>Geht jetzt alles. Fettes Danke!!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1578870</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1578870</guid><dc:creator><![CDATA[Egleria]]></dc:creator><pubDate>Mon, 08 Sep 2008 20:09:29 GMT</pubDate></item><item><title><![CDATA[Reply to &amp;quot;error LNK2019: Verweis auf nicht aufgelöstes externes Symbol&amp;quot; on Mon, 08 Sep 2008 20:15:19 GMT]]></title><description><![CDATA[<blockquote>
<p>5 STunden sitzt ich nun schon an diesen Fehler und ich Depp sehs nicht</p>
</blockquote>
<p>Siehs positiv: Diesen Fehler machst du nie mehr. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1578873</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1578873</guid><dc:creator><![CDATA[drakon]]></dc:creator><pubDate>Mon, 08 Sep 2008 20:15:19 GMT</pubDate></item></channel></rss>