Microsoft
98-363 · Question #18
A Web page has an <asp:Button> control and three <asp:TextBox> controls named txt1, txt2, and txt3. When a user clicks the <asp:Button> control, the Web page calls a JavaScript function named Sum()…
The correct answer is D. OnClientClick="Sum();". See the full explanation below for the reasoning.
Question
A Web page has an asp:Button control and three asp:TextBox controls named txt1, txt2, and txt3. When a user clicks the asp:Button control, the Web page calls a JavaScript function named Sum(). Sum () adds the values of txt1 and txt2, and places the resulting value into txt3. Which attribute should you set on the asp:Button control to call Sum()?
Options
- AOnClick="Sum();"
- BCommandName="Sum();"
- COnCommand="Sum();"
- DOnClientClick="Sum();"
How the community answered
(33 responses)- A3% (1)
- B12% (4)
- C6% (2)
- D79% (26)
Community Discussion
No community discussion yet for this question.