Chapter 8 Two Truths & a Lie
Two of the following statements are true, and one is false. Identify the false statement: a. The default methods generated when you double-click a Control in the IDE are known as procedures. b. A Form can contain any number of Controls that might have events associated with them, and a single Control might be able to raise any number of events. c. You can type any statements you want within an automatically generated event method.
a. The default methods generated when you double-click a Control in the IDE are known as procedures.
Two of the following statements are true, and one is false. Identify the false statement: a. When an event occurs, any delegate that a client has given or passed to the event is invoked. b. Built-in event handler delegates have two arguments, but those you create yourself have only one. c. You can take only two actions on an event field: composing a new delegate onto the field using the += operator, and removing a delegate from the field using the -= operator.
b. Built-in event handler delegates have two arguments, but those you create yourself have only one.
Two of the following statements are true, and one is false. Identify the false statement: a. The Control TabStop property can be set to true or false; it identifies whether the Control will serve as a stopping place in a sequence of Tab key presses. b. On a Form with multiple Controls, one Control must have a TabIndex value of 0. c. When a Form contains multiple Controls, you can associate the same event with all of them.
b. On a Form with multiple Controls, one Control must have a TabIndex value of 0.
Two of the following statements are true, and one is false. Identify the false statement: a. An action such as a key press or button click raises an event. b. A method that performs a task in response to an event is an event handler. c. The control that generates an event is an event receiver.
c. The control that generates an event is an event receiver.
Two of the following statements are true, and one is false. Identify the false statement: a. The delegate used to create mouse event handlers is MouseEventHandler. b. Keyboard events, also known as key events, occur when a user presses and releases keyboard keys. c. Unlike mouse events, every keyboard event-handling method must be parameterless.
c. Unlike mouse events, every keyboard event-handling method must be parameterless.