GSSP-NET · Question #217
Martha works as a Software Developer for NetCom Inc. She develops an application, named App1, using Visual Studio .NET. The application contains a form, named MyForm1. MyForm1 contains several…
The correct answer is B. Martha has set the CausesValidation property of txtDOB to False. See the full explanation below for the reasoning.
Question
Martha works as a Software Developer for NetCom Inc. She develops an application, named App1, using Visual Studio .NET. The application contains a form, named MyForm1. MyForm1 contains several controls including a TextBox, named txtDOB. The txtDOB control is used to accept the date of birth from a user. In order to ensure that a user enters a valid date in txtDOB, Martha adds validation logic to the Validating event of txtDOB. When she tests the form by using some invalid dates in txtDOB, the validation logic does not appear to be working as expected. What is the most likely cause of the issue?
Options
- AMartha has set the Locked property of txtDOB to True.
- BMartha has set the CausesValidation property of txtDOB to False.
- CMartha has set the SuppressValidation property of txtDOB to True.
- DMartha has set the TabIndex property of txtDOB to 0.
How the community answered
(17 responses)- A6% (1)
- B76% (13)
- C6% (1)
- D12% (2)
Community Discussion
No community discussion yet for this question.