Yes, you can have many return points.
Yes, you can have many return points.
ThanksRegards
And reffering to lineEdit's text, here's quote from docs:
access functions doesn't say how to refer to lineEdit's text. QString text () const it's just a declaration of a string. void setText ( const QString & ) is to set the lineEdit's text. And I still don't know how to operate on lineEdit's text.This property holds the line edit's text.
Setting this property clears the selection, clears the undo/redo history, moves the cursor to the end of the line and resets the modified property to false. The text is not validated when inserted with setText().
The text is truncated to maxLength() length.
Access functions:
*
QString text () const
*
void setText ( const QString & )
See also insert() and clear().
Hmm? Do you know the meaning of the word "access"?
Hmm?QString text () const it's just a declaration of a string.
It's a declaration of a function/method that is called "text", returns a "QString" object and takes no arguments (implicit void).
Correct.void setText ( const QString & ) is to set the lineEdit's text.
How about just trying to use the "text()" method?And I still don't know how to operate on lineEdit's text.
Is something like this correct?
is that the "text method"?Qt Code:
To copy to clipboard, switch view to plain text mode
No, it doesn't make any sense.
Please learn a bit of C++...
Thanks, now's clear. And if in lineEdit is an integer, I should use int (quint) instead of QString, right?
edit:
this problem wasn't about my c++ skills, but logical methods, I had no idea about it
But text can be an integer. So how can I operate on integers which are in lineEdit?
Search QString docs and pick a method that converts the string to int.
J-P Nurmi
Thanks, I'll read it
Bookmarks