Im trying to retrieve the text() value from a simple QLineEdit
function but I'm unable to make it work, I'm new to Qt so I'm kinda lost, especially when using pointers.
Inside my ui_Ventas2.h
file, Qt already initialize all the classes
QLineEdit *lineClienteNo;
but when I want to retrieve the text i do something like this, on my main.cpp
file
QLineEdit *ClienteNo;
ClienteNo->lineClienteNo.text();
I'm doing something very basic, yet I can't link it, here's my full code:
#include <QApplication>
#include "Ventas2.h"
#include "ui_Ventas2.h"
int main(int argc, char *argv[]) {
QApplication app(argc, argv);
Ventas2 VentanaPrincipal;
VentanaPrincipal.show();
QLineEdit *ClienteNo;
ClienteNo->lineClienteNo.text();
return app.exec();
}
Should I make a new class on my Ventas2.h
header file to link the created class from Qt to make it work or something??
Note: I'm using Netbeans 8.1 and the Qt Framework 5.7 on Mac