In pratica voglio solo eseguire il ciclo di una stringa di caratteri per estrarre ciascuno e ognuno deve essere di tipo const char * così posso passarlo a una funzione. ecco un esempio. Grazie per l'aiuto.C++ converte char in const char *
string thestring = "abc123";
const char* theval;
string result;
for(i = 0; i < thestring.length(); i++){
theval = thestring[i]; //somehow convert this must be type const char*
result = func(theval);
}
Vuoi chiamare il func() con "a", poi "b" e così via? Perché? Questa domanda è difficile da rispondere. –