About Me

My photo
Northglenn, Colorado, United States
I'm primarily a BI Developer on the Microsoft stack. I do sometimes touch upon other Microsoft stacks ( web development, application development, and sql server development).

Wednesday, September 20, 2006

MS ASP.Net Assessment Question: Cancelling a logon event.

You create a Web Form. The Web Form allows users to log on to an application. You include a Login control named Login1. You want to be able to cancel the logon process when a user clicks the Log on button in the Login1 control.

You need to write code in one of Login1's event handlers to cancel the logon process.

What should you do?

A)Write code in the Login1_Load event handler.
B)Write code in the Login1_LoginError event handler.
C)Write code in the Login1_LoggedIn event handler.
D)Write code in the Login1_LoggingIn event handler.
E)Write code in the Login1_Authenticate event handler.


A is wrong since there is no Load event for the Login Control.
B is wrong since this only occurs when the login event throws an error.
C is wrong since the user is logged into the site and is authenticated.
D is probably the best answer since the process of logging on is still taking place and authentication has not occured yet.
E is wrong because the user would have already been authenicated by then.

No comments: