<?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[[C++ Error] mainE.cpp(3464): E2314 Aufruf einer Nicht-Funktion]]></title><description><![CDATA[<p>hei<br />
bekomme diesen Fehler: Aufruf einer Nicht-Funktion<br />
was ist bei &quot;SaveProjectLabel(1,File(fileName));&quot; falsch?</p>
<pre><code class="language-cpp">void __fastcall TMain::editExeSettings()
{
ofstream File(fileName);                //open settings file
SaveProjectLabel(1,File(fileName));
...
File.close();
}
</code></pre>
<pre><code class="language-cpp">void __fastcall TMain::SaveProjectLabel(int iIndex,TObject *ofstream)
{
...
}
</code></pre>
<p>bis bald dieleena</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/164692/c-error-maine-cpp-3464-e2314-aufruf-einer-nicht-funktion</link><generator>RSS for Node</generator><lastBuildDate>Wed, 12 Aug 2026 11:32:59 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/164692.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 11 Nov 2006 16:04:51 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to [C++ Error] mainE.cpp(3464): E2314 Aufruf einer Nicht-Funktion on Sat, 11 Nov 2006 16:04:51 GMT]]></title><description><![CDATA[<p>hei<br />
bekomme diesen Fehler: Aufruf einer Nicht-Funktion<br />
was ist bei &quot;SaveProjectLabel(1,File(fileName));&quot; falsch?</p>
<pre><code class="language-cpp">void __fastcall TMain::editExeSettings()
{
ofstream File(fileName);                //open settings file
SaveProjectLabel(1,File(fileName));
...
File.close();
}
</code></pre>
<pre><code class="language-cpp">void __fastcall TMain::SaveProjectLabel(int iIndex,TObject *ofstream)
{
...
}
</code></pre>
<p>bis bald dieleena</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1172560</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1172560</guid><dc:creator><![CDATA[dieleena]]></dc:creator><pubDate>Sat, 11 Nov 2006 16:04:51 GMT</pubDate></item><item><title><![CDATA[Reply to [C++ Error] mainE.cpp(3464): E2314 Aufruf einer Nicht-Funktion on Sat, 11 Nov 2006 16:59:46 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>so richtig hast du Parameter und Funktionen noch nicht verstanden. Fangen wir mit der Funktion selber an. Du willst offenbar einen Stream als Parameter übergeben. Aber Parameter werden grundsätzlich als <em>Typ Name</em> definiert, und ofstream hat nichts mit TObject zu tun. Und als Name des Parameters sollte auch kein bereits definiertes Symbol genommen werden. Zu letzt sollten komplexe Typen (alles auser int, char, float...) als (konstante) Referenzen übergeben werden.<br />
Zusammenfassend ist also das die korrekte Schreibweise :</p>
<pre><code class="language-cpp">void __fastcall TMain::SaveProjectLabel(int Index, ofstream&amp; Stream)
{
...
}
</code></pre>
<p>Dann kannst du auf diese Funktion zugreifen, aber ohne eine unsinnige Funktionsdeklaration</p>
<pre><code class="language-cpp">ofstream File(fileName);                //open settings file
SaveProjectLabel(1, File);
</code></pre>
<p>bis bald<br />
akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1172600</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1172600</guid><dc:creator><![CDATA[akari]]></dc:creator><pubDate>Sat, 11 Nov 2006 16:59:46 GMT</pubDate></item><item><title><![CDATA[Reply to [C++ Error] mainE.cpp(3464): E2314 Aufruf einer Nicht-Funktion on Sat, 11 Nov 2006 17:08:33 GMT]]></title><description><![CDATA[<p>hei,<br />
dieses hatte ich auch getestet.</p>
<pre><code class="language-cpp">SaveProjectLabel(1, File);
</code></pre>
<p>Auch hier der gleiche Fehler.<br />
Dies ist der Fehler, den ich gemacht habe. &quot;TObject *ofstream&quot;</p>
<pre><code class="language-cpp">void __fastcall TMain::SaveProjectLabel(int iIndex,TObject *ofstream)
</code></pre>
<p>Super, Danke,<br />
bis bald dieleena</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1172605</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1172605</guid><dc:creator><![CDATA[dieleena]]></dc:creator><pubDate>Sat, 11 Nov 2006 17:08:33 GMT</pubDate></item><item><title><![CDATA[Reply to [C++ Error] mainE.cpp(3464): E2314 Aufruf einer Nicht-Funktion on Sat, 11 Nov 2006 17:22:34 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>Nochmal : ofstream hat nichts mit TObject zu tun.<br />
Meine Veränderungen sind schon insgesamt nötig. Stell sicher, das auch in der Headerdatei von TMain auch die Funktion SaveProjectLabel als Member des Forms dekalriert ist, und oben in der Headerdatei der notwendige STL-Include steht</p>
<pre><code class="language-cpp">#include &lt;fstream&gt; // Ohne .h!
</code></pre>
<p>Desweiteren solltest du auch immer den Namespace mitverwenden</p>
<pre><code class="language-cpp">void __fastcall TMain::SaveProjectLabel(int Index, std::ofstream&amp; Stream)
{
...
}
</code></pre>
<pre><code class="language-cpp">std::ofstream File(fileName); 
// std::ofstream File(fileName.c_str()); falls fileName ein AnsiString ist
SaveProjectLabel(1, File);
</code></pre>
<p>Wenn du immer noch Fehler bekommst, poste deinen relevanten Code mitsamt Deklarationen und Headerdatei.</p>
<p>bis bald<br />
akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1172618</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1172618</guid><dc:creator><![CDATA[akari]]></dc:creator><pubDate>Sat, 11 Nov 2006 17:22:34 GMT</pubDate></item></channel></rss>