Probleme mit QString iVm QDict

Alles rund um die Programmierung mit Qt
Antworten
pumbah
Beiträge: 31
Registriert: 19. August 2005 21:13

Probleme mit QString iVm QDict

Beitrag von pumbah »

Hi,

ich habe ein QDict-Objekt erstellt dessen Werte QStringobjekte sein sollen.

QDict<QString> trans;
QString k;
QString v;
...
# füttern
trans.insert(k, new QString(v) );
v = "";
...
# ausgeben
QDictIterator<QString>it( trans );
for ( ; it.current(); ++it)
cout << it.currentKey() << " " << *it.current() << endl;
}

Frage: Wie muss ich trans füttern (anhand von insert), wenn ich anschliessend die Ausgabe nicht über *ti.current() sondern über it.current() machen will?

Ich habe es probiert aber nicht hinbekommen. :oops:

cu,

pumbah
Antworten