Multiple choice technology programming languages

What is the first method that is fired during page load?

  1. Prerender()

  2. Init()

  3. Load()

  4. Unload()

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

In ASP.NET page lifecycle, Init() is the first method fired during page load, followed by Load(), then other events like PreRender(). Unload() is called much later when the page is destroyed.

AI explanation

To answer this question, you need to understand the page life cycle in web development.

The correct answer is B) Init(). This method is the first method that is fired during page load.

Here's an explanation of each option:

A) Prerender() - This method is called after the Init() method and before the Load() method. It is not the first method fired during page load.

B) Init() - This method is the first method that is fired during page load. It is used to initialize the page and its controls.

C) Load() - This method is called after the Init() method and Prerender() method. It is used to load the page and its controls.

D) Unload() - This method is called when the page is unloaded or disposed. It is not the first method fired during page load.

Therefore, the correct answer is B) Init(). This option is correct because it is the first method that is fired during page load, as mentioned in the question.