<?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[string anstatt const char* ?]]></title><description><![CDATA[<p>Hallo,<br />
ich habe ein Programm geschrieben und benutze die Funktion system(). Ich verwendete die ganze Zeit einen festen Eintrag für system(). Nachdem ich den festen Eintrag durch eine Variable vom Typ string ersetzt habe erhalte ich folgende Fehlermeldung:</p>
<p>&quot;cannot convert `std::string' to `const char*' for argument `1' to `int system(const char*)'&quot;</p>
<p>Meine Frage ist, wie kann ich das umgehen so das ich eine string Variable verwenden kann? Gibt es da eine Möglichkeit?</p>
<p>Danke</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/149453/string-anstatt-const-char</link><generator>RSS for Node</generator><lastBuildDate>Sat, 05 Sep 2026 07:40:34 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/149453.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 06 Jun 2006 09:27:18 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to string anstatt const char* ? on Tue, 06 Jun 2006 09:27:18 GMT]]></title><description><![CDATA[<p>Hallo,<br />
ich habe ein Programm geschrieben und benutze die Funktion system(). Ich verwendete die ganze Zeit einen festen Eintrag für system(). Nachdem ich den festen Eintrag durch eine Variable vom Typ string ersetzt habe erhalte ich folgende Fehlermeldung:</p>
<p>&quot;cannot convert `std::string' to `const char*' for argument `1' to `int system(const char*)'&quot;</p>
<p>Meine Frage ist, wie kann ich das umgehen so das ich eine string Variable verwenden kann? Gibt es da eine Möglichkeit?</p>
<p>Danke</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072278</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072278</guid><dc:creator><![CDATA[ratlos2006]]></dc:creator><pubDate>Tue, 06 Jun 2006 09:27:18 GMT</pubDate></item><item><title><![CDATA[Reply to string anstatt const char* ? on Tue, 06 Jun 2006 09:31:24 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>siehe <a href="http://www.cppreference.com/cppstring/c_str.html" rel="nofollow">std::string::c_str()</a></p>
<p>bis bald<br />
akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072285</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072285</guid><dc:creator><![CDATA[akari]]></dc:creator><pubDate>Tue, 06 Jun 2006 09:31:24 GMT</pubDate></item><item><title><![CDATA[Reply to string anstatt const char* ? on Tue, 06 Jun 2006 09:42:11 GMT]]></title><description><![CDATA[<p>Danke für die schnelle Antwort... hat super geklappt.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072296</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072296</guid><dc:creator><![CDATA[ratlos2006]]></dc:creator><pubDate>Tue, 06 Jun 2006 09:42:11 GMT</pubDate></item></channel></rss>