prompt for input in qlineedit - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: GUI (https://python-forum.io/forum-10.html) +--- Thread: prompt for input in qlineedit (/thread-27797.html) |
prompt for input in qlineedit - GMCobraz - Jun-22-2020 Hi all, May I know how to call for prompt for an input in qlineedit? For example: 1. User first input a value in qlineedit. 2. I program to check whether the input is integer only, if not ask user to input again in same qlineedit. Please help. Thanks RE: prompt for input in qlineedit - Knight18 - Jun-22-2020 Are you looking for a way to prompt the user? If so, then use the QMessageBox widget. Or were you asking something else? RE: prompt for input in qlineedit - menator01 - Jun-22-2020 Have a look at this https://stackoverflow.com/questions/13422995/set-qlineedit-to-accept-only-numbers RE: prompt for input in qlineedit - GMCobraz - Jun-22-2020 Dear all, Thanks for the reply. I found a better way to do it. Instead of asking the user to input and check whether is integer or not in qlineedit. I use qspinbox to solve this problem. User can either input integer or double only, not something else. Thanks. |