Home

Asp Programming MCQ Solved Paper for NDA

Thursday 9th of March 2023

Sharing is caring

1. In a DataSet if multible tables are used, they are identified by their
A. Names
B. Indexes
C. Any one of the above
D. None of the above
Answer : C
2. We can manage states in asp.net application using
A. Session Objects
B. Application Objects
C. Viewstate
D. All of the above
Answer : D
3. While redirecting, values can be passed with it
A. True
B. False
C.
D.
Answer : A
4. Default event handler for Link Label is
A. LinkClicked
B. Clicked
C. LinkActivated
D. ActiveLinkClicked
Answer : A
5. ____________ enables you to add, modify and delete records and you will see the changes made by other users
A. OpenForwardOnly
B. OpenKeyset
C. OpenDynamic
D. OpenStatic
Answer : C
6. In ASP.NET a page is inherited from System.Web.UI.Page. Here UI means
A. Universal Indicator
B. Uniform Indicator
C. User Interface
D. Universal Interface
Answer : C
7. To make an HTML control behave as a Server control, ___________ option must be set.
A. Server Control
B. Run As Server Control
C. Run As Web Control
D.
Answer : B
8. Error handling can be done through Global.asax
A. True
B. False
C.
D.
Answer : A
9. The code file for WebForm1.aspx will be ___________
A. WebForm1.vbp
B. WebForm1.vb
C. WebForm1.frm
D. WebForm1.sln
Answer : B
10. There can be more than one Global.asax file
A. True
B. False
C.
D.
Answer : B
11. HTML tag equivalent to Panel is
A. Div
B. Br
C. P
D. Span
Answer : A
12. Caching type supported by ASP.Net
A. Output Caching
B. DataCaching
C. a and b
D. none of the above
Answer : C
13. In ASP.NET, the default method of a form is
A. Get
B. Post
C.
D.
Answer : B
14. ASP.NET supports all data types that VB.NET supports
A. True
B. False
C.
D.
Answer : A
15. You can specify a function name in
A. CustomValidator
B. RequiredFieldValidator
C. RangeValidator
D. ValidationSummary
Answer : A
16. To save an XML file from ASP.NET use
A. Save
B. Update
C. SaveXML
D. UpdateXML
Answer : A
17. Default Session data is stored in ASP.Net.
A. StateServer
B. Session Object
C. InProcess
D. all of the above
Answer : C
18. You can send an e-mail with an attachment using only SmtpMail class
A. True
B. False
C.
D.
Answer : B
19. One difference between ASP.NET and ASP is that ASP is more structure than ASP.NET
A. True
B. False
C.
D.
Answer : B
20. _________ object represents all information sent form a server to a browser
A. Response
B. Request
C. Session
D. Application
Answer : A
21. To count the number of times an user visited a page, use
A. Session variables
B. Application variables
C. Cookies
D. Server variables
Answer : C
22. Which of the following method must be overridden in a custom control?
A. The Paint() method
B. The Control_Build() method
C. The default constructor
D. The Render() method
Answer : D
23. ASP.NET uses _______ as the code behind
A. VB
B. VBScript
C. JavaScript
D. Jscript
Answer : A
24. If a Table controls name is Table1, to access value from its second row, third column, __________________ can be used.
A. table1.rows(1).cells(2).text
B. table1.rows(2).cells(3).text
C. table1.rows(1).cells(2).value
D. table1.rows(2).cells(3).value
Answer : A
25. Web.config file is used...
A. Configures the time that the server-side codebehind module is called
B. To store the global information and variable definitions for the application
C. To configure the web server
D. To configure the web browser
Answer : B
26. Can you have more than one form declaration on a web form?
A. Yes
B. No
C.
D.
Answer : B
27. In ___________ records are read-only and cannot be changed.
A. LockReadOnly
B. LockPessimistic
C. LockOptimistic
D. LockDynamic
Answer : A
28. We can write an XML document from ASP.NET without mentioning the encoding format ie even without specifying 'Nothing'
A. True
B. False
C.
D.
Answer : B
29. In the Adrotator XML file ________ is used to mention the file to link to
A. <ImageUrl>
B. <NavigateUrl>
C. <Url>
D. <Link>
Answer : B
30. How do you get information from a form that is submitted using the "post" method?
A. Request.QueryString
B. Request.Form
C. Response.write
D. Response.writeln
Answer : B
31. You need to modify an ASP.NET page to prevent the browser window from going blank after a postback and to maintain the correct control focus after events are processed. What should you do?
A. Add the following attribute to the HTML code for the controls that cause the postbacks:
RunAt="client"
B. Add the following attribute to the HTML code for the controls that cause the postbacks:
EnableViewState="True"
C. Add the following attribute to the Page directive for the aspx file:
SmartNavigation="True"
D. Add the following attribute to the OutputCache directive for the aspx file:
Location="client
Answer : C
32. __________ and __________ event are the two most commonly supported server-side events. (Click and Change)
A. Click and Change
B. Click and DblClick
C. KeyUp and KeyDown
D. KeyEnter and KeyPress
Answer : A
33. Which of the following object is not an ASP component?
A. LinkCounter
B. Counter
C. AdRotator
D. File Access
Answer : A
34. ______________ creates a read-only recordset that can scroll in any direction.
A. OpenForwardOnly
B. OpenKeyset
C. OpenDynamic
D. OpenStatic
Answer : D
35. In ___________ records are locked when you start editing.
A. LockReadOnly
B. LockPessimistic
C. LockOptimistic
D. LockDynamic
Answer : B
36. To make a RepeaterControl viewable, the controls ____________ must be edited
A. DataSource
B. DataMember
C. ItemTemplate
D. Template
Answer : D
37. Menus can be added to an ASP.NET Page
A. True
B. False
C.
D.
Answer : B
38. To set text programmatically without adding extra HTML tags use
A. Literal
B. Response.Write
C. Both of the above
D. None of the above
Answer : C
39. Of the following controls which can be used to add a control at runtime
A. Panel
B. Image
C. Label
D. All of the above
Answer : D
40. Which DLL translate XML to SQL in IIS?
A. SQLISAPI.dll
B. SQLXML.dll
C. LISXML.dll
D. SQLIIS.dll
Answer : A
41. In ASP.NET if a file is saved, it is save only in the server machine.
A. True
B. False
C.
D.
Answer : A
42. ____________ converts virtual path to default path
A. Server.MapPath and Request.MapPath
B. Server.MapPath and Response.MapPath
C. Response.MapPath and Request.MapPath
D. All of the above
Answer : B
43. ASP.NET use
A. Compiler
B. Interpreter
C.
D.
Answer : A
44. If a page name is WebForm1.aspx and it resides in ../Test/, then it will inherit from
A. WebForm1
B. WebForm1/Test
C. Test/WebForm1
D. Test.WebForm1
Answer : D
45. To send attachments using SMTP use
A. MailAttachment and MailMessage
B. CDO
C. Any one of the above
D. None of the above
Answer : A
46. Anything appearing before ________ is cleared
A. Response.Flush
B. Response.End
C. Response.Buffer
D. Response.Clear
Answer : D
47. ASP.NET if fully compatible with ASP
A. True
B. False
C.
D.
Answer : B
48. ASP.NET is object oriented
A. True
B. False
C.
D.
Answer : A
49. Why is Global.asax is used?
A. Declare Global variables
B. Implement application and session level events
C. No use
D. Both a and b
Answer : B
50. Which of the following tool is used to manage the GAC?
A. RegSvr.exe
B. GacUtil.exe
C. GacSvr32.exe
D. GacMgr.exe
Answer : B

Sharing is caring