Home

LSAT - Asp Programming 1000+ MCQ [Solved] PDF Download

Thursday 9th of March 2023

Sharing is caring

1. In ___________ records are locked when you start editing.
A. LockReadOnly
B. LockPessimistic
C. LockOptimistic
D. LockDynamic
Answer : B
2. How can you check if the page is visited for the first time
A. Use PostBack
B. Use IsPostBack
C. Use Post
D. Use Get
Answer : B
3. Cookies collection is present in
A. Response and Request
B. Request and Server
C. Response and Server
D. All of the above
Answer : A
4. Anything appearing after ________ is cleared
A. Response.Flush
B. Response.End
C. Response.Buffer
D. Response.Clear
Answer : B
5. The default method of a WebForm is
A. Page_Load
B. WebForm_Load
C. Form_Load
D. Page_Init
Answer : A
6. 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
7. Caching type supported by ASP.Net
A. Output Caching
B. DataCaching
C. a and b
D. none of the above
Answer : C
8. What are unique properties of RangeValidator control?
A. Maximum value
B. Minimum value
C. Type
D. All of the above
Answer : D
9. ASP.NET supports all data types that VB.NET supports
A. True
B. False
C.
D.
Answer : A
10. Cookies can be created with mentioning the expiry date
True

A.
B. False
C.
D.
Answer : B
11. In case of RangeValidator, a TextBox's value can be compared to the values taken from two other TextBoxes
A. True
B. False
C.
D.
Answer : A
12. What keyword is necessary to expose a public function as a method of a Web Service?
A. WebSub()
B. WebFunction()
C. WebMethod()
D. WebClass
Answer : C
13. A web server control is written as
A. <asp-TextBox ......
B. <asp TextBox ......
C. <aspTextBox ........
D. <asp:TextBox ........
Answer : D
14. A ValidationSummary control is bound to a control
A. True
B. False
C.
D.
Answer : B
15. HTML elements, HTML server controls and ASP.NET server controls can be used on the same form
A. True
B. False
C.
D.
Answer : A
16. One difference between ASP.NET and ASP is that ASP is more structure than ASP.NET
A. True
B. False
C.
D.
Answer : B
17. Default event handler for Link Label is
A. LinkClicked
B. Clicked
C. LinkActivated
D. ActiveLinkClicked
Answer : A
18. Error handling can be done through Global.asax
A. True
B. False
C.
D.
Answer : A
19. You want to ensure that the user ID is saved between requests when the user is moving through pages. What will you do?
A. Use Session variables
B. Use Application variables
C. Any one of the above
D. No of the above
Answer : A
20. To display HTML tags as it is use
A. Encode
B. HTMLEncode
C. URLEncode
D. EncodeHTML
Answer : B
21. Radio Button's have same name and different values while Checkboxes have the reverse
A. True
B. False
C.
D.
Answer : A
22. In case of a CompareValidator, a TextBox's value can be compared to an expression
A. True
B. False
C.
D.
Answer : B
23. File extension used for ASP.NET files.
A. .Web
B. .ASP
C. .ASPX
D. None of the above
Answer : B
24. In the Adrotator XML file ________ is used to mention the file to link to
A. <ImageUrl>
B. <NavigateUrl>
C. <Url>
D. <Link>
Answer : B
25. ASP.NET if fully compatible with ASP
A. True
B. False
C.
D.
Answer : B
26. This file stores your web configuration
A. Web.conf
B. Web.config
C. WebConfig.ini
D. WebConf.ini
Answer : B
27. Which DLL translate XML to SQL in IIS?
A. SQLISAPI.dll
B. SQLXML.dll
C. LISXML.dll
D. SQLIIS.dll
Answer : A
28. What is the default data type of a variable in ASP.NET?
A. Variant
B. Object
C. Integer
D. String
Answer : B
29. In ASP.NET, the default method of a form is
A. Get
B. Post
C.
D.
Answer : B
30. ____________ enables you to set a particular date when a page should no longer be cached by a browser or proxy server
A. Response.Expires
B. Session.Timeout
C. Response.ExpiresAbsolute
D. Response.CacheControl
Answer : C
31. ____________ enables you to add, modify and delete records but you won't see the changes made by other users
A. OpenForwardOnly
B. OpenKeyset
C. OpenDynamic
D. OpenStatic
Answer : B
32. 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
33. __________ 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
34. There can be more than one Global.asax file
A. True
B. False
C.
D.
Answer : B
35. To read an XML file from ASP.NET use
A. XMLTextReader
B. XMLReader
C. XML.Reader
D. ReadXML
Answer : A
36. What class does a Web Service Inherit?
A. System.Web.Services
B. System.Web
C. System.Services
D. System.Web.Page
Answer : A
37. We can manage states in asp.net application using
A. Session Objects
B. Application Objects
C. Viewstate
D. All of the above
Answer : D
38. ______________ creates a read-only recordset that can scroll forward only.
A. OpenForwardOnly
B. OpenKeyset
C. OpenDynamic
D. OpenStatic
Answer : A
39. ASP.NET can be installed on Windows 98 machine
A. True
B. False
C.
D.
Answer : B
40. ____________ 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
41. Difference between Response.Write() andResponse.Output.Write().
A. Response.Output.Write() allows you to buffer output
B. Response.Output.Write() allows you to write formatted output
C. Response.Output.Write() allows you to flush output
D. Response.Output.Write() allows you to stream output
Answer : B
42. What class does the ASP.NET Web Form class inherit from by default?
A. System.Web.UI.Page
B. System.Web.UI.Form
C. System.Web.GUI.Page
D. System.Web.Form
Answer : A
43. Which of the following object is not an ASP component?
A. LinkCounter
B. Counter
C. AdRotator
D. File Access
Answer : A
44. 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
45. While accessing values submitted to a web form, __________ property of a control is used.
A. Value
B. Text
C. Item
D. Id
Answer : A
46. CDO stands for _________________ .
A. Collaborative Database Object
B. Collaborative Data Object
C. Collaborative Distributed Object
D. Complete Data Object
Answer : B
47. Choose the form in which Postback occur
A. HTMLForms
B. Webforms
C. Winforms
D. None of these
Answer : B
48. For Adrotator control the XML file is mentioned through ________ property
A. File
B. Name
C. Advertisement File
D. Ad File
Answer : C
49. What is used to validate complex string patterns like an e-mail address?
A. Extended expressions
B. Basic expressions
C. Regular expressions
D. Irregular expressions
Answer : C
50. Under Button Click the following code is written
1. Dim I =10
2. MsgBox(I)

A. Problem is in line 1
B. Problem is in line 2
C. Will display 10 in a message box
D. Compilation Error
Answer : C

Sharing is caring