SyntaxFix
Write A Post
Hire A Developer
Questions
If you're using QT Creator 5.6 you can do that like this:
#include <QIntValidator> ui->myLineEditName->setValidator( new QIntValidator);
I recomend you put that line after ui->setupUi(this);
I hope this helps.