Cannot Convert 'int' to 'const char *'
<p>I'm working with c++ and XE8. Given the following code:</p>

<pre><code>String __fastcall RemoveCharsFromString(String &amp;str, const String &amp;c)
{
    for(unsigned int i=0; i&lt;c.Length(); ++i)
    {
        str.Delete(std::remove(str[0], str.LastChar(), c[i]), str.LastChar());
    }
}
</code></pre>

<p>Received errors:</p>

<ul>
<li><p>Using <code>str.Delete(remove(str[0], str.LastChar(), c[i]), str.LastChar());</code> results in a </p>

<blockquote>
  <p>Cannot convert 'int' to 'const char *'</p>
</blockquote>

<p>error inside the for loop.</p></li>
<li><p>Using <code>str.Delete(std::remove(str[0], str.LastChar(), c[i]), str.LastChar());</code> results in a </p>

<blockquote>
  <p>Could not find a match for 'remove(wchar_t,wchar_t*,wchar_t)'</p>
</blockquote>

<p>error inside the for loop.</p></li>
</ul>

<p>Searching SO and the web, it's my understanding this error is usually received when code  is written with single quotes when double quotes should have been used. I don't believe that scenario is applicable in this case.</p>

<p>The return type of <code>String</code> is Embarcadero's <code>UnicodeString</code>. Details can be found here: <a href="http://docs.embarcadero.com/products/rad_studio/delphiAndcpp2009/HelpUpdate2/EN/html/delphivclwin32/System__UnicodeString.html" rel="nofollow">RAD Studio VCL Reference - UnicodeString Class</a></p>