PDA

View Full Version : can't get Qdate



mmm286
4th March 2010, 09:21
Hi,

I have:
QString comHora = lineaHora.left(6);

comHora=100303

If I do:

QDate dia = QDate::fromString(comHora,"yyMMdd");
hora->setText("Timess: " + dia.toString());

It gives me:
jue mar 3 1910

I would like to get: 100303

Could you help me please?
Thanks

mmm286
4th March 2010, 09:25
Well.

I must put:

hora->setText("Timess: " + dia.toString("yyMMdd"));


Jejeje, I'm newbie!
Sorry