GIAC
GSSP-NET · Question #306
David works as a Software Developer for McRobert Inc. He develops a Windows-based application, named App1, using Visual C# .NET. The application contains a Form control, named Form1. He wants to…
The correct answer is B. private void Form1_Load(System.Object sender, System.EventArgs e) {. See the full explanation below for the reasoning.
Question
David works as a Software Developer for McRobert Inc. He develops a Windows-based application, named App1, using Visual C# .NET. The application contains a Form control, named Form1. He wants to write code to initialize class-level variables, named Var1, Var2, and Var3, as soon as Form1 is instantiated. Which of the following code will he use to accomplish this?
Options
- Aprivate void Form1_Initialize(System.Object sender, System.EventArgs e) {
- Bprivate void Form1_Load(System.Object sender, System.EventArgs e) {
- Cprivate void Form1_New(System.Object sender, System.EventArgs e) {
- Dprivate void Form1_Create(System.Object sender, System.EventArgs e) {
How the community answered
(38 responses)- A5% (2)
- B82% (31)
- C11% (4)
- D3% (1)
Community Discussion
No community discussion yet for this question.