câu hỏi trắc nghiệm web - Pdf 12

Trắc nghiệm Asp (chính xác 99.99%)
1. What does ASP stand for?
a. All Standard Pages
b. A Server Page
c. Active Standard Pages
d. Active Server Pages

2. ASPserverscriptsaresurroundedbydelimiters,which?
a. <&> </&>
b. <script> </script>
c. <%> </%>
d. <% %>

3. Howdoyouwrite"HelloWorld"inASP
a. Response.Write("HelloWorld")

b. Document.Write("HelloWorld")//javascript
c. "HelloWorld"
4. "<%="isthesameas:
a. <%Equal
b. <%Write
c. <%Response.Write

d. <%Document.Write
5. WhatisthedefaultscriptinglanguageinASP?
a. JavaScript
b. EcmaScript
c. PERL
d. VBScript

6. HowcanyouscriptyourASPcodeinJavaScript?

12. AllusersofthesameapplicationshareONEApplicationobject.
a. True

b. False
13. IfauserhasCookiesenabled,asessionvariableisavailabletoallpagesinoneapplication.
a. False
b. True

14. Global.asaisrequiredforallWebsites
a. OnlyforASPWebsites
b. True

c. False
TRẮC NGHIỆM ASP.NET (99 CÂU)
1. Which of the following languages can be used to write server side scripting in ASP.NET?
A) C#
B) C
C) Visual Basic
2. The Following are the minimum requirement to run Asp.net pages
A) Java Virtual Machine
B) Common Language Runtime
C) Windows explorer
3. When a .aspx page is requested from the web server, the out put will be rendered to browser in following
format.
A) HTML
B) XML
C) WML
4. What executable unit gets created when we build an ASP.Net application?
A) . EXE
B) . DLL

12. Which method do you invoke on the Data Adapter control to load your generated dataset
A) Fill ( )
B) ExecuteQuery ( )
C) Read ( )
13. How many configuration files can an ASP.NET projects have?
A) One
B) More Than One
C) None
14. How do you register a user control?
A) Add Tag prefix, Tag name
B) Add Source, Tag prefix
C) Add Src, Tagprefix, Tagname
15. How do you post the current page to a different aspx page ?
A) FORM ACTION="actiopage.aspx" RUNAT="server" method="post"
B) FORM ACTION="actiopage.aspx" method="post"
C) FORM id="Form1" method="post" runat="server"
16. Which of these namespaces used for FileAccess
A) System.IO
B) System.IO.IsolatedStorage
C) System.DirectoryServices
D) All of these
17. Which of the following is true ?
A) User controls are displayed correctly in the Visual Studio .NET Designer
B) Custom controls are displayed correctly in VS.Net Designer
C) User and Custom controls are displayed correctly in the Visual Studio .NET Designer.
18. Can a dll run as stand alone application ?
A) No
B) Yes
C) Sometimes we can make it by introducing some code
19. To add a custom control to a Web form we have to register with

26. There can be more than 1 machine.config file in a system
A) True
B) False
27. What is the extension of a web user control file ?
A) .Asmx
B) . Ascx
C) .Aspx
28. What is the default session out time
A) 20 Sec
B) 20 Min
C) 1 hr
29. Which of the following is true ?
A) IsPostBack is a method of System.UI.Web.Page class
B) IsPostBack is a method of System.Web.UI.Page class
C) IsPostBack is a readonly property of System.Web.UI.Page class
30. It is possible to set Maximum length for a text box through code
A) True
B) False
31. The number of forms that can be added to a aspx page is
A) 2
B) 3
C) 1
D) More than 3
32. How do you manage states in asp.net application
A) Session Objects
B) application Objects
C) Viewstate
D) Cookies
E) All of the above
33. what is the difference between user control and custom control

A) FieldValidator
B) RegularExpressionValidator
C) RangeValidator
D) PatternValidator
40. How do you trace the application_End event on runtime?
A) By Debugging
B) By Tracing
C) Can not be done
41. How do you turn off the Session state for a webform ?
A) In Web.config file set the tag to True
B) In Web.config file set the tag to false
C) Set the Session state to false in webform properties window
D) Set the EnableSession state to false in webform properties window
42. Who can access Session state variables
A) All Users of an application
B) A Single session
C) All users within a single tunnel
43. Select the type Processing model that asp.net simulate
A) Event-driven
B) Static
C) Linear
D) TopDown
44. Does the “EnableViewState” allows the page to save the users input on a form
A) Yes
B) No
45. Web Controls Supports CSS
A) True
B) False
46. Session Object classes are defined in which of the following namespace?
A) System.Web.UI

B) Session.Discard ( )
C) Session.Abandon
D) Session.End
53. Why do we use XMLSerializer class
A) Remoting
B) WebServices
C) Xml documentary Files
54. What does Response.End will do?
A) It will stop the server process
B) It will stop the client process
C) None of the above
55. Which control supports paging
A) Repeater
B) Datagrid
C) Both
D) None
56. Where do you store the information about the user locale
A) System.user
B) System.web
C) System.Drawing
D) System.Web.UI.Page.Culture
57. What is the purpose of code behind ?
A) To separate different sections of a page in to different files
B) To merge HTML layout and code in to One file
C) To separate HTML Layout and code to different file
D) To ignore HTML usage
58. What is a satallite assembly ?
A) Any DLL file used by an EXE file.
B) An Assembly containing localized resources for another assembly
C) None of the above

A) DataRelation
B) DataRelationship
C) DataConstraint
D) Datakey
66. Which one of the following namespaces contains the definition for IdbConnection
A) System.Data.Interfaces
B) System.Data.Common
C) System.Data
D) System.Data.Connection
67. Select the Interface which provides Fast, connected forward-only access to data
A) IdataRecord
B) Idatabase
C) IdataReader
D) Irecorder
68. How do we Delete, Update, Select data in a Dataset
A) Using SQLDataAdapter
B) Using SQLDataReader
C) Using SQLCommand
D) None
69. Which of the following is not a member of ConnectionObject
A) BeginTransaction
B) EndTransaction
C) Execute
D) Open
70. Is it Possible to Serialize HashTable with XMLSerializer
A) Yes
B) No
71. What is the Full Form of WSDL
A) Web System Description Language
B) Web Services Detail Language

78. Is it possible edit data in a repeater control
A) No
B) Yes
79. Why is Global.asax is used for ?
A) To implement application & Session level events
B) To store configuration information
C) To store styling information
D) None of the above
80. What is a diffgram ?
A) The one which renders the dataset object contents to XML
B) Finds the difference in two objects
C) Finds the difference in two files
D) None of the above
81. What is the lifespan for items stored in viewstate
A) Exists for the Life of the current page
B) 20 mins
C) 2 mins
D) 2 sec
82. What data types do a Rangevalidator supports
A) Integer
B) String
C) Date
D) All of the above
83. Select the output of the statement < form method=post action=”test.aspx” >
A) Transfers all the form data to test.aspx with HTTP headers
B) Transfers all the form data to test.aspx with out HTTP headers
C) Calls post method on test.aspx
D) None of the above
84. What is the out put of the following codebyte a=200;byte b=100;byte c=a+b;Response.Write ( C );
A) 300

B) Clears all the section value from rendered HTML File
C) Clears the content of the Rendered page
D) None of the above
91. What is the significance of Response.AddHeaders( )
A) Adds HTTP Headers to output stream
B) Adds Tag to rendered Page
C) Add Headers to the web site
92. What is the difference between HTTP handlers & HTTP modules
A) Httphandler is an class and Httpmodule is an assembly
B) Httphandler is an event handler and httpmodule is module to do some task
C) Both of the above
D) None of the above
93. Which namespace allows us to formauthentication ?
A) System.Web.Ui.Forms.Security
B) System.Web.Security
C) System.Web.Configuration
D) System.Web.Services
94. Which method displays the custom control
A) The Prerender
B) Render
C) Page_Load
D) Display
95. When is the user controls code is executed
A) After the webform loads
B) After the page_init event of webform
C) Before Page_init event of web form
96. Client Sertificate is a collection of
A) Server
B) Response
C) Collection

1. What does CSS stand for?
a. Colorful Style Sheets
b. Creative Style Sheets
c. Computer Style Sheets
d. Cascading Style Sheets

2. What is the correct HTML for referring to an external style sheet?
a. <style src="mystyle.css">
b. <link rel="stylesheet" type="text/css" href="mystyle.css">

c. <stylesheet>mystyle.css</stylesheet>
3. Where in an HTML document is the correct place to refer to an external style sheet?
a. At the end of the document
b. In the <body> section
c. In the <head> section

d. At the top of the document
4. Which HTML tag is used to define an internal style sheet?
a. <style>

b. <css>
c. <script>
5. WhichHTMLattributeisusedtodefineinlinestyles?
a. Styles
b. Font
c. Class
d. Style

6. WhichisthecorrectCSSsyntax?
a. {body;color:black}

c. text‐style
d. text‐size
12. WhatisthecorrectCSSsyntaxformakingallthe<p>elementsbold?
a. <pstyle="font‐size:bold">
b. <pstyle="text‐size:bold">
c. p{font‐weight:bold}

d. p{text‐size:bold}
13. Howdoyoudisplayhyperlinkswithoutanunderline?
a. a{text‐decoration:none}

b. a{underline:none}
c. a{text‐decoration:nounderline}
d. a{decoration:nounderline}
14. Howdoyoumakeeach wordinatextstartwithacapitalletter?
a. text‐transform:uppercase
b. text‐transform:capitalize

c. Youcan'tdothatwithCSS
15. Howdoyouchangethefontofanelement?
a. f:
b. font=
c. font‐family:

16. Howdoyoumakethetextbold?
a. font‐weight:bold

b. style:bold
c. font:b
17. Howdoyoudisplayaborderlikethis:

b. Hyperlinks and Text Markup Language
c. Home Tool Markup Language
2. Who is making the Web standards?
a. Mozilla
b. The World Wide Web Consortium

c. Microsoft
3. Choose the correct HTML tag for the largest heading
a. <h1>

b. <head>
c. <h6>
d. <heading>
4. What is the correct HTML tag for inserting a line break?
a. <break />
b. <br />

c. <lb />
5. What is the correct HTML for adding a background color?
a. <background>yellow</background>
b. <body style="background-color:yellow">

c. <body background="yellow">
6. Choose the correct HTML tag to make a text bold
a. <bold>
b. <b>

7. Choose the correct HTML tag to make a text italic
a. <i>


d. <td valign="left">
13. How can you make a list that lists the items with numbers?
a. <ol>

b. <list>
c. <dl>
d. <ul>
14. How can you make a list that lists the items with bullets?
a. <ol>
b. <ul>

c. <dl>
d. <list>
15. What is the correct HTML for making a checkbox?
a. <checkbox>
b. <input type="checkbox" />

c. <input type="check" />
d. <check>
16. What is the correct HTML for making a text input field?
a. <textinput type="text" />
b. <textfield>
c. <input type="textfield" />
d. <input type="text" />

17. What is the correct HTML for making a drop-down list?
a. <select>

b. <list>
c. <input type="list" />

d. ("Hello World")
3. Where is the correct place to insert a JavaScript?
a. The <body> section
b. The <head> section
c. Both the <head> section and the <body> section are correct

4. What is the correct syntax for referring to an external script called "xxx.js"?
a. <script src="xxx.js">

b. <script href="xxx.js">
c. <script name="xxx.js">
5. An external JavaScript must contain the <script> tag
a. False

b. True
6. How do you write "Hello World" in an alert box?
a. alertBox("Hello World")
b. alert("Hello World")

c. alertBox="Hello World"
d. msgBox("Hello World")
7. How do you create a function?
a. function myFunction()

b. function=myFunction()
c. function:myFunction()
8. How do you call a function named "myFunction"?
a. myFunction()

b. call myFunction()

a. //This comment has
more than one line//
b. <! This comment has
more than one line >
c. /*This comment has

more than one line*/

15. What is the correct way to write a JavaScript array?
a. var txt = new Array(1:"tim",2:"kim",3:"jim")
b. var txt = new Array("tim","kim","jim")

c. var txt = new Array="tim","kim","jim"
d. var txt = new Array:1=("tim")2=("kim")3=("jim")
16. How do you round the number 7.25, to the nearest integer?
a. Math.rnd(7.25)
b. Math.round(7.25)

c. rnd(7.25)
d. round(7.25)
17. How do you find the number with the highest value of x and y?
a. Math.ceil(x,y)
b. top(x,y)
c. Math.max(x,y)

d. ceil(x,y)
18. What is the correct JavaScript syntax for opening a new window called "w2" ?
a. w2=window.new("");
b. w2=window.open("");


3 You are working on a JavaScript project. What is used to restart the inner most loop?
Abort
Breakloop
Stop
Continue label
4 You work on a JavaScript project. Which of the following correctly describe the
relationships of JavaScript and "objects"?
JavaScript is Object-oriented
JavaScript is Object-based
JavaScript is Object-driven
JavaScript has no relationship with objects
5 You work on a JavaScript project. How do you prompt users with messages and
at the same time requesting user inputs?
Alert()
Display()
Prompt()
Confirm()
6 Which of the following is the correct syntax of FOR?
for ( increment; initialize; test)
for ( initialize; test), increment
for ( initialize; test; increment)
for ( test; initalize; increment)
7 In your JavaScript code, how do you find out which character occurs at the
5th position in a string "How are you"?
Substring()
String()
Stringlength()
CharAt()
8 Which of the following do you use for a multi-way branch?
If

at debug time
at code time
14 Which of the following correctly describe cookies ?
Often referred to as "persistent cookies"
Often referred to as "persistent HTML"
Small memory-resident pieces of information sent from a server to the client
Small memory-resident pieces of information sent from a client to the server
Either AB&C
15 A program written by JavaScript is driven by
Events
Classes
Objects
Components
16 What are JavaScript relations with the underlying operating platform?
Platform dependent
Platform linkage
Platform independent
Platform binding
17 When you plan for the JavaScript variable names, the first character must be?
Underscore
Comma
Letter
Either A&D
18 Which of the following correctly describe JavaScript as a language?
It is based on object creation
It focuses on component building
It focuses on logic flow
It emphasis on SCRIPTING
19 When authoring web page with Javascript, why should you explicitly include
the window object into your codes?

Two. The "for" loop and the "while" loop
Four. The "for" loop, the "while" loop, the "do while" loop, and the "loop until" loop
One. The "for" loop
None of the above
26 How does a "for" loop start?
for (i = 0; i <= 5)
for (i = 0; i <= 5; i++)
for i = 1 to 5
for (i <= 5; i++)
27 What is the correct way to write a JavaScript array?
var txt = new Array(1:"tim",2:"shaq",3:"kobe")
var txt = new Array="tim","shaq","kobe"
var txt = new Array("tim","shaq","kobe")
all of the above are incorrect
28 How do you round the number 8.25, to the nearest whole number?
Math.rnd(8.25)
Math.round(8.25)
round(8.25)
rnd(8.25)
29 How do you find the largest number of 6 and 8?
Math.max(6,8)
top(6,8)
ceil(6,8)
Math.ceil(6,8)
30 What is the correct JavaScript syntax for opening a new window called "window5" ?
new("","window5")
window.open("","window5")
open.newwindow("","window5")
new.window("","window5")
31 How do you put a message in the browser's status bar?

a Active Standard Pages
b A Server Page
c Active Server Pages
d All Standard Pages
2 ASP server scripts are surrounded by delimiters, which?
a <&> </&>
b <% %>
c <%> </%>
d <script> </script>
3 How do you write "Hello World" in ASP (ASP NET)
a Response.Write("Hello World");
b Document.Write("Hello World");
c System.io.println("Hello World");
d Print("Hello World");
4 "<%=" is the same as:
a <%Response.Write
b <%Document.Write
c <%Write
d <%Equal
5 What server-language can be used in ASP.Net ?
a C Shell
b PERL
c Java
d VB NET
6 How do you get information from a form that is submitted using the "get" method?
a Request.Form
b Request.QueryString
c Request.Get
d all a,b,c are correct
7 Page 1 has this link: <a href="page2.aspx?color=green">Go</a>

13 Which one of these events is a standard Global.asax event?
Session_OnEnd
Application_Error
Appication_OnStart
Global.asax doesn't have any standard events
14 Global.asax is required for all Web sites
TRUE
FALSE
ASP website, and APSX website
only for APSX website
15 Which of the following languages can be used to write server side scripting in ASP.NET?
C-sharp
VB
C++
a and b
16 When an .aspx page is requested from the web server, the out put will be rendered
to browser in following format.
HTML
XML
WML
JSP
17 The Asp.net server control, which provides an alternative way of displaying text on web page, is
< asp:label >
< asp:listitem >
< asp:button >
none of them
18 The first event to be triggered in an aspx page is.
Page_Load()
Page_Init()
Page_Click()

All of the above
24 Custom Controls are derived from which of the classes
System.Web.UI.Webcontrol
System.Web.UI.Customcontrol
System.Web.UI.Customcontrols.Webcontrol
None of them
25 How ASP.Net Different from classic ASP?
Scripting is separated from the HTML, Code is interpreted seperately
Scripting is separated from the HTML, Code is compiled as a DLL, the DLLs can be executed on server
Code is separated from the HTML and interpreted Code is interpreted separately
All are incorrect
26 What's the difference between Response.Write() andResponse.Output.Write()?
Response.Output.Write() allows you to flush output
Response.Output.Write() allows you to buffer output
Response.Output.Write() allows you to write formatted output
Response.Output.Write() allows you to stream output
27 Why is Global.asax is used?
Implement application and session level events
Declare Global variables
To calculate number visitors
No use
28 What is the extension of a web user control file?
.Asmx
.Ascx
.Aspx
.cs
29 Which of the following is true?
IsPostBack is a method of System.UI.Web.Page class
IsPostBack is a method of System.Web.UI.Page class
IsPostBack is a readonly property of System.Web.UI.Page class

Topdown
36 Does the EnableViewState allows the page to save the users input on a form?
Yes
No
37 Which DLL translate XML to SQL in IIS?
SQLISAPI.dll
SQLXML.dll
LISXML.dll
SQLIIS.dll
38 What is the maximum number of cookies that can be allowed to a web site?
1
10
20
More than 30
39 Select the control which does not have any visible interface


Nhờ tải bản gốc

Tài liệu, ebook tham khảo khác

Music ♫

Copyright: Tài liệu đại học © DMCA.com Protection Status