Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Qt and QDateTime example I
#include <QCoreApplication>
//Lembre de fazer include das classes
#include <QDebug>
#include <QDateTime>
#include <QDate>
#include <QTime>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
// QDate(ano, mes, dia)
// QTime(hora, minuto, segundo)
QDateTime today(QDate(2016, 6,19), QTime(22,10,0));
qDebug() << " today " << today.toString();
return a.exec();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment