hi,
Do you want get data from QLineEdit box ?
the follwing function should return what ever lineedit box contains
QString displayText() and QString text();
more details ,refer Qt Assistant
hi,
Do you want get data from QLineEdit box ?
the follwing function should return what ever lineedit box contains
QString displayText() and QString text();
more details ,refer Qt Assistant
If u want to get the value of text box from a QWidget to MainWindow,
declare an instance of QWidget say MyQWidget in ur MainWindow then u can get the value by MyQWidget->MyTextBox->text();
Or if u r doing all the things in designer(i.e. u r not creating any implementation header or source file) then the place where u r actually getting the text string, store this in an extern variable and access this extern variable in ur MainWindow.
But I would not recommend this approach, its better that u should create the implementation files for both ur QWidget and MainWindow, then implement the functionality there.
Bookmarks