ASP.NET MCQ Questions with Answers – Part 1

Microsoft ASP.NET Multiple Choice Questions Answers Interview Set Exam Techhyme

ASP.NET is a radical update of Microsoft’s Active Server Pages (ASP). ASP.NET is a powerful server based technology designed to create dynamic and interactive HTML pages on demand for your Web site or corporate intranet. Its design improves upon nearly every feature of classic ASP, from reducing the amount of code you need to write to giving you more power and flexibility.

Presently we have added total 4 sets of questions on ASP.NET programming for you to practice. We will keep adding more questions and provide this question bank in PDF format too, so that you can download them instantly in E-book style.

We have listed below the best ASP.NET MCQ (Multiple Choice Questions) with Answers, that check your basic knowledge of ASP.NET. This ASP.NET MCQ Set contains 55 ASP.NET Multiple Choice Questions with Answers. You have to select the right answer to check your final preparation for the ASP.NET Exam/Interviews.

1. ASP.NET web pages are written using

A. VB.NET
B. C#
C. C++
D. VBScript

Correct Answer – A, B

2. The ASP.NET engine requires

A. .NET OS
B. .NET Framework
C. .NET Source Code
D. None of the above

Correct Answer – B

3. ASP.NET can be used to create

A. E-commerce web sites
B. Intranet web sites
C. Corporate web sites
D. All of the above

Correct Answer – D

4. ASP.NET web pages run on

A. The server side
B. The client side
C. Both the server side and the client side
D. None of the above

Correct Answer – A

5. The ASl’.NET engine runs on

A. The server side
B. The client side
C. Both the server side and the client side
D. None of the above

Correct Answer – A

6. The .NET Framework contains

A. Customer information
B. Classes
C. Account information
D. All of the above

Correct Answer – B

7. You can write an ASP.NET web page using any editor.

A. True
B. False

Correct Answer – A

8. All dynamic web pages must be generated by ASPNET web pages.

A. True
B. False

Correct Answer – B

9. There is a visible difference between HTML markup code in a static web page and a dynamic one.

A. True
B. False

Correct Answer – B

10. A dynamic web page cannot contain images or audio.

A. True
B. False

Correct Answer – B

11. An HTML server control is

A. Another term for HTML markup code
B. Instructions for the ASP.NET engine to use an HTML class in .NET Framework
C. Instructions for the ASP.NET engine to use a web control class in .NET Framework
D. Another term for web control

Correct Answer – B

12. A class is an instance of an object.

A. True
B. False

Correct Answer – B

13. The Response. Write() method

A. Sends HTML controls to the client
B. Sends web controls to the client
C. Sends characters to the client
D. None of the above

Correct Answer – C

14. An event handler is

A. Something that occurs while the ASPNET executes
B. A block of code that executes in reaction to a specified event
C. Another term for an event
D. Code that sends an event to an ASP.NET web page

Correct Answer – B

15. Page-Load

A. Is the way a client requests a page from the web server
B. Starts the web server
C. Starts the ASP.NET engine
D. Is the name of the event handler for the Page-Load event

Correct Answer – D

16. An ASPNET web page is divided into an HTML portion and a source code portion.

A. True
B. False

Correct Answer – A

17. Event handlers must be defined within the script tag.

A. True
B. False

Correct Answer – A

18. A method is

A. An action associated with a class
B. Data associated with a class
C. An instance of a class
D. None of the above

Correct Answer – A

19. The runat=”server” attribute means

A. Start the web server
B. Start the ASP.NET engine
C. Execute the code on the server side
D. None of the above

Correct Answer – A

20. The sequence c%@ Page Language=”VB7′ %> is a directive.

A. True
B. False

Correct Answer – A

21. The ID property is

A. Used as the text for an element
B. Used as the value for an element
C. Used to uniquely ID an element
D. None of the above

Correct Answer – C

22. The design phase is where you write code for your application.

A. True
B. False

Correct Answer – B

23. You prevent a visitor from changing the value of a text box element by

A. Setting the Visible property
B. Setting the Invisible property
C. Setting the Read-only property to True
D. None of the above

Correct Answer – C

24. Values can be combined by using

A. The equal sign
B. The assignment operator
C. The equivalence operator
D. The plus sign

Correct Answer – D

25. You store information into a text box from within your code by using

A. The equal sign
B. The copy property
C. The equivalence operator
D. The plus sign

Correct Answer – A

26. The testing phase is where bugs are discovered and fixed.

A. True
B. False

Correct Answer – A

27. You create an event handler for a button control by double-clicking a button on the Design tab.

A. True
B. False

Correct Answer – A

28. You can change the property of an element by

A. Using the Property pane
B. Using the Visible property of the element
C. Using the Read Only property of the element
D. None of the above

Correct Answer – A

29. CreateAccount.Visible = False means

A. Making an element visible
B. Making an element invisible
C. Making an element accessible
D. None of the above

Correct Answer – B

30. Literal values must be enclosed with quotations in your code.

A. True
B. False

Correct Answer – A

31. “Bob” is a(n)

A. Integer
B. Short
C. Long
D. None of the above

Correct Answer – D

32. A comparison operator is used to define the condition for ASP.NET to make a decision.

A. True
B. False

Correct Answer – A

33. Initialization is assigning

A. The first value to a variable
B. A value to a variable
C. A string to a variable
D. An integer to a variable

Correct Answer – A

34. The c operator is used to determine if the value on the left side of the operator is

A. Equal to the value on the right side of the operator
B. Not equal to the value on the right side of the operator
C. Less than the value on the right side of the operator
D. Greater than the value on the right side of the operator

Correct Answer – C

35. A variable is

A. A temporary storage place in memory
B. A constant value
C. A value that cannot be changed
D. None of the above

Correct Answer – A

36. String values must be enclosed within quotations.

A. True
B. False

Correct Answer – A

37. An expression using the XOr operator is true if both the logical expressions joined together by the XOr operator are true.

A. True
B. False

Correct Answer – B

38. The And Also logical operator tells the ASP.NET engine

A. Not to evaluate the second logical expression if the first logical expression is true
B. To evaluate the second logical expression if the first logical expression is true
C. Not to evaluate the second logical expression if the first logicalexpression is false
D. None of the above

Correct Answer – C

39. The Not operator tells the ASPNET to

A. Skip evaluating the expression
B. Skip evaluating the expression only if the expression is false
C. Reverse the logic of the expression after evaluating the expression
D. None of the above

Correct Answer – C

40. You can convert from one data type to another using casting.

A. True
B. Fals

Correct Answer – A

41. What loop executes statements if a condition is false?

A. Do While loop
B. Do Until loop
C. Until loop
D. None of the above

Correct Answer – B

42. What loop executes statements if a condition is true?

A. Do While loop
B. Do Until loop
C. Until loop
D. None of the above

Correct Answer – A

43. The counter range in the for loop is used to

A. Increase the expression by 1.
B. Determine the range of values used to control the iterations of the loop by the ASPNET engine.
C. Limit the number of statements that can be contained in the code block.
D. Limit the output of statements within the code block.

Correct Answer – B

44. A Case statement cannot have a default Case.

A. True
B. False

Correct Answer – B

45. A For loop can skip values in the counter range.

A. True
B. False

Correct Answer – A

46. What would you use if you want a block of statements to be executed only if a condition isn’t true?

A. If … then
B. If … Then … Else
C. For loop
D. For in loop

Correct Answer – B

47. The default clause is used in an If statement to set default values.

A. True
B. False

Correct Answer – B

48. What is the purpose of Elseif in an If … Then … Elseif statement?

A. Contains statements that are executed only if the conditional expression is true.
B. Defines another conditional expression the ASP.NET engine evaluates if the first conditional expression is false.
C. Contains statements that are executed only if the conditional expression is false.
D. Is used to nest an If statement.

Correct Answer – B

49. Statements within a for loop can reference the For loop variable.

A. True
B. False

Correct Answer – A

50. A Case statement is ideal to use to evaluate a menu option selected by a visitor to your web site.

A. True
B. False

Correct Answer – A

51. This is the first element of the products array: products[l].

A. True
B. False

Correct Answer – B

52. How many elements are there in Dim productsA() AS String = {“Soda”, “Water”, “Pizza” )?

A. 2
B. 3
C. 4
D. None

Correct Answer – B

53. What method would you use to reset values of an array?

A. Reset ()
B. Copy0
C. Clear ()
D. Reboot ()

Correct Answer – C

54. What method is used to search for a value in an array?

A. Index Of ()
B. LastIndex Of ()
C. Binary Search ()
D. All of the above

Correct Answer – D

55. What method is used to copy a segment of an array to another array?

A. Copy ()
B. SigCopy ()
C. Part copy ()
D. Short Copy ()

Correct Answer – A

Related Useful Articles: