<?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[Runtime Error]]></title><description><![CDATA[<p>Hallo erstmal,</p>
<p>ich schreibe grade mal wieder ein Programm. Ich denke, was es macht, müsst ihr nicht wissen. Wenn doch, sagt bescheid. Das Problem ist, dass dabei ein Runtime Error (&quot;This appliaction has requested the runtime to terminate it in an unusual way. Please contact the applications support team for more information&quot;) auftritt. Bei einem ganz bestimmten Code. Hier das ganze Programm:</p>
<pre><code class="language-cpp">#include &lt;cstdlib&gt;
#include &lt;iostream&gt;
#include &lt;fstream&gt;
#include &lt;windows.h&gt;
#include &quot;nexus.h&quot;
#include &quot;scmmod.h&quot;

using namespace std;

int step = 0;
string t_typ;
string triggernew;

int main()
{
    colwhite
    string start_t = get_path(&quot;data\\text.ini&quot;,&quot;start&quot;);
    cout&lt;&lt;start_t&lt;&lt;endl&lt;&lt;endl;

    string gsfile;
    cin&gt;&gt;gsfile;

    Trigger_Start:

    string op_code = readf(gsfile,step);

    if (op_code != &quot;TRIGGERS&quot;) {
        colred
        cout&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;line1error&quot;);
        colwhite
        Sleep(2000);
        return 0;
    }

    step++;

    //////////////////Weiter zur Triggerverarbeitung////////////////////

    Trigger_Routine:

    string trigger = readf(gsfile,step);

    if (trigger == &quot;END&quot;) {
        goto next_step; //Nächster Block
    }

    cout&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;triggertyp&quot;);
    cout&lt;&lt;endl&lt;&lt;endl;
    colyellow
    cout&lt;&lt;op_code.substr(10,op_code.find(&quot;;&quot;)-11);
    colwhite

    cin&gt;&gt;t_typ;

    if (trigger_checktyp(t_typ) != 1) {
        colred
        cout&lt;&lt;endl&lt;&lt;endl&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;triggertyp_error&quot;)&lt;&lt;endl&lt;&lt;endl;
        colwhite
    }

    triggernew = &quot;%%&quot;;
    triggernew += readf(gsfile,step).substr(0,8);
    triggernew += &quot;%%&quot;;

    cout&lt;&lt;&quot;triggernew:   &quot;&lt;&lt;triggernew&lt;&lt;&quot;  &quot;;

    replacef(gsfile,triggernew,completef(t_typ + &quot;.ini&quot;));

    step++;
    goto Trigger_Routine;

    next_step:

              cout&lt;&lt;&quot;Fertig!&quot;;
              Sleep(3500);
              return 0;

}
</code></pre>
<p>Der Code in Zeile 74 macht Probleme. Wenn ich ihn deaktiviere klappt alles wunderbar. Bei einem ähnlichen Code (auch mit substr() ) hatte ich sowas schonmal. DAS hab ich da aber noch umgehen können. Woran liegt es, dass dieser Error da kommt aber bei anderen substr() Codes nicht? Ich benutze den Code oft und es gibt keine Probleme. Wie gesagt, ich denke nicht, dass ihr den Sinn braucht, das wäre nämlich eine etwas längere Erklärerei. Falls doch, sagt bescheid. Vorher hatte ich nie solche Probleme. Liegt es vielleicht an Vista?</p>
<p>P.S.: Die Funktionen writef, readf, replacef und die anderen ...-f Funktionen sind selbstgeschrieben in der nexus.h. Einige andere sind auch da oder in der anderen Headerdatei. colyellow, colred und colwhite sind auch in der nexus.h als #define deklariert.</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/189602/runtime-error</link><generator>RSS for Node</generator><lastBuildDate>Fri, 25 Sep 2026 09:46:39 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/189602.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 14 Aug 2007 22:41:22 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Runtime Error on Tue, 14 Aug 2007 22:41:22 GMT]]></title><description><![CDATA[<p>Hallo erstmal,</p>
<p>ich schreibe grade mal wieder ein Programm. Ich denke, was es macht, müsst ihr nicht wissen. Wenn doch, sagt bescheid. Das Problem ist, dass dabei ein Runtime Error (&quot;This appliaction has requested the runtime to terminate it in an unusual way. Please contact the applications support team for more information&quot;) auftritt. Bei einem ganz bestimmten Code. Hier das ganze Programm:</p>
<pre><code class="language-cpp">#include &lt;cstdlib&gt;
#include &lt;iostream&gt;
#include &lt;fstream&gt;
#include &lt;windows.h&gt;
#include &quot;nexus.h&quot;
#include &quot;scmmod.h&quot;

using namespace std;

int step = 0;
string t_typ;
string triggernew;

int main()
{
    colwhite
    string start_t = get_path(&quot;data\\text.ini&quot;,&quot;start&quot;);
    cout&lt;&lt;start_t&lt;&lt;endl&lt;&lt;endl;

    string gsfile;
    cin&gt;&gt;gsfile;

    Trigger_Start:

    string op_code = readf(gsfile,step);

    if (op_code != &quot;TRIGGERS&quot;) {
        colred
        cout&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;line1error&quot;);
        colwhite
        Sleep(2000);
        return 0;
    }

    step++;

    //////////////////Weiter zur Triggerverarbeitung////////////////////

    Trigger_Routine:

    string trigger = readf(gsfile,step);

    if (trigger == &quot;END&quot;) {
        goto next_step; //Nächster Block
    }

    cout&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;triggertyp&quot;);
    cout&lt;&lt;endl&lt;&lt;endl;
    colyellow
    cout&lt;&lt;op_code.substr(10,op_code.find(&quot;;&quot;)-11);
    colwhite

    cin&gt;&gt;t_typ;

    if (trigger_checktyp(t_typ) != 1) {
        colred
        cout&lt;&lt;endl&lt;&lt;endl&lt;&lt;get_path(&quot;data\\text.ini&quot;,&quot;triggertyp_error&quot;)&lt;&lt;endl&lt;&lt;endl;
        colwhite
    }

    triggernew = &quot;%%&quot;;
    triggernew += readf(gsfile,step).substr(0,8);
    triggernew += &quot;%%&quot;;

    cout&lt;&lt;&quot;triggernew:   &quot;&lt;&lt;triggernew&lt;&lt;&quot;  &quot;;

    replacef(gsfile,triggernew,completef(t_typ + &quot;.ini&quot;));

    step++;
    goto Trigger_Routine;

    next_step:

              cout&lt;&lt;&quot;Fertig!&quot;;
              Sleep(3500);
              return 0;

}
</code></pre>
<p>Der Code in Zeile 74 macht Probleme. Wenn ich ihn deaktiviere klappt alles wunderbar. Bei einem ähnlichen Code (auch mit substr() ) hatte ich sowas schonmal. DAS hab ich da aber noch umgehen können. Woran liegt es, dass dieser Error da kommt aber bei anderen substr() Codes nicht? Ich benutze den Code oft und es gibt keine Probleme. Wie gesagt, ich denke nicht, dass ihr den Sinn braucht, das wäre nämlich eine etwas längere Erklärerei. Falls doch, sagt bescheid. Vorher hatte ich nie solche Probleme. Liegt es vielleicht an Vista?</p>
<p>P.S.: Die Funktionen writef, readf, replacef und die anderen ...-f Funktionen sind selbstgeschrieben in der nexus.h. Einige andere sind auch da oder in der anderen Headerdatei. colyellow, colred und colwhite sind auch in der nexus.h als #define deklariert.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1344678</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1344678</guid><dc:creator><![CDATA[Alemarius Nexus]]></dc:creator><pubDate>Tue, 14 Aug 2007 22:41:22 GMT</pubDate></item><item><title><![CDATA[Reply to Runtime Error on Wed, 15 Aug 2007 00:07:10 GMT]]></title><description><![CDATA[<p>OMG.<br />
In &quot;op_code&quot; steht &quot;TRIGGERS&quot; wenn du an die Stelle kommst, sonst würde der niemals über das &quot;if (op_code != &quot;TRIGGERS&quot;) { ... return 0; }&quot; drüberkommen. Danach machst du ein &quot;op_code.substr(10, ...)&quot;. Fällt dir was auf? Ich meine &quot;TRIGGERS&quot; ist 8 Zeichen lang, und du greifst auf Index 10 zu.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1344686</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1344686</guid><dc:creator><![CDATA[hustbaer]]></dc:creator><pubDate>Wed, 15 Aug 2007 00:07:10 GMT</pubDate></item><item><title><![CDATA[Reply to Runtime Error on Wed, 15 Aug 2007 01:23:57 GMT]]></title><description><![CDATA[<p>Mist, das ist mir schonmal passiert aber da ist es mir aufgefallen. Das kommt davon, wenn man ein Programm tausend mal neu anfängt. Ich bin übrigens nicht so blöd, dass ich da auf einen zu hohen Index zugreife, sondern ich habe vergessen die nächste Zeile anstatt der ersten zu benutzen.</p>
<p>Naja, danke jedenfalls für die Hilfe</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1344692</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1344692</guid><dc:creator><![CDATA[Alemarius Nexus]]></dc:creator><pubDate>Wed, 15 Aug 2007 01:23:57 GMT</pubDate></item><item><title><![CDATA[Reply to Runtime Error on Thu, 16 Aug 2007 00:47:15 GMT]]></title><description><![CDATA[<p>Naja... um deine Worte zu verwenden: du bist anscheinend &quot;zu blöd&quot; um einen Debugger (sinnvoll) zu verwenden, sonst hättest du den Fehler sofort erkannt und niemals dieses Posting gepostet <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="😉"
    /><br />
BTW: mit &quot;goto&quot; nach oben springen ist PFUI.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1345436</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1345436</guid><dc:creator><![CDATA[hustbaer]]></dc:creator><pubDate>Thu, 16 Aug 2007 00:47:15 GMT</pubDate></item></channel></rss>