QT生成GUID

#include <QCoreApplication>

#include <QUuid>
#include <QDebug>

int main(int argc, char *argv[])
{
    QCoreApplication a(argc, argv);

   QUuid id = QUuid::createUuid();
   QString strId = id.toString();
   qDebug()<< strId;
    return a.exec();
}

 

posted @ 2018-06-28 16:43  风来风往风伤(TiAmo)  阅读(5950)  评论(0编辑  收藏  举报