Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Consider the following statements and answer the questions that follow them: QString userInput = QInputDialog::getText ( 0 , User Details, Enter your full name (
Consider the following statements and answer the questions that follow them:
QString userInput QInputDialog::getText "User Details", "Enter your full name each word separated by :;
QStringList userInfo userInput.split:;
ifuserInfolength
QMessageBox::warning "Error", "Enter your full name!", ;
else
QMessageBox::information"Result",QStringYour name consists of words."arguserInfolength;
Write a nonempty input string that the user can enter in the QInputDialog dialog that will be bring up the error message in the QMessageBox dialog in the code above.
Write the output string displayed in the QMessageBox dialog when the user enters the string Mike:William:Owen in the QInputDialog dialog.
What is the effect of entering a number, say in the above QInputDialog dialog?
Explain one similarity and one difference between QInputDialog and QMessageBox dialogs for obtaining user input.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started