Set - 7

Question 1 :

What is job?

Answer :

It can be defined as a task performed by a computer system. For example, printing a file is a job. Jobs can be performed by a single program or by a collection of programs.

Question 2 :

What is Task?

Answer :

Whenever you execute a program, the operating system creates a new task for it. The task is like an envelope for the program: it identifies the program with a task number and attaches other bookkeeping information to it.

Question 3 :

How do you find the error, how can you know the number of rows affected by last SQL Statement?

Answer :

@@errors->give the last error occurred in the current DB.
Ans. select @@rowcount

Use @@ERROR which returns the error number for the last Transact-SQL statement executed fro knowing the error.
Use @@ROWCOUNT which returns the number of rows affected by the last statement for finding the no of rows affected.

Question 4 :

What are the advantages/disadvantages of viewstate?

Answer :

Disadvantages - Because the view state for a given page must be kept on the server, it is possible for the current state to be out of synchronization with the current page of the browser, if the user uses the Back feature on the browser to go back in the history. Advantages - On ordinary Web Forms pages, their view state is sent by the server as a hidden variable in a form, as part of every response to the client, and is returned to the server by the client as part of a postback. However, to reduce bandwidth demand when using mobile controls, ASP.NET does not send a page's view state to the client. Instead, the view state is saved as part of a user's session on the server. Where there is a view state, a hidden field that identifies this page's view state is sent by the server as part of every response to the client, and is returned to the server by the client as part of the next request.

Question 5 :

Describe session handling in webform. How does it work and what are the limits?

Answer :

Session management in ASP.NET can be done in two ways:
Using Cookies
Encoding of URLs with Session ID

Question 6 :

Explain differences between framework 1.0 and framework 1.1?

Answer :

1. Native Support for Developing Mobile Web Applications
2. Unified Programming Model for Smart Client Application Development
3. Enable Code Access Security for ASP.NET Applications
4. Native Support for Communicating with ODBC and Oracle Databases
5. Supports for IPv6

Question 7 :

If we write any code for dataGrid methods, what is the access specifier used for that methods in the code behind file and why and how? Give an example.

Answer :

We use Friends Modifer for the dataGrid methods. Friend WithEvents DataGrid1 As System.Windows.Forms.DataGrid

Question 8 :

What is the use of trace utility?

Answer :

Tracing is a very important monitoring and debugging tool for distributed, multitier applications. Such applications often contain problems that can only be observed when the application is under a heavy load and the inherent randomness of a real-life environment. Trace utility allows developers and administrators to monitor the health of applications running in real-life settings.

Question 9 :

What are the differences between User control and Web control and Custom control?

Answer :

Usercontrol-> control that is created as u wish.
Web Control-> any control placed in web page (web application page)
Custom Control-> same as user control with some difference.

user control custome control
1.easy to create difficult full suport for customers using
Visual studio tools Full support
3. Seperate copy of the control in each
assembly only one copy in global assembly.
4. best for static layout best for dynamic layout.

User control
1) Reusability web page
2) We can't add to toolbox
3) Just drag and drop from solution explorer to page (aspx)
4) Good for static layout
5) Easier to create
6) Not complied into DLL

Custom controls
1) Reusability of control (or extend functionalities of existing control)
2) We can add toolbox
3) Just drag and drop from toolbox
4) You can register user control to. Aspx page by Register tag
5) A single copy of the control is required in each application
6) Good for dynamic layout
7) Hard to create
8) Compiled in to dll

Custom controls
1) Reusability of control
2) Pre defined Control
3) Just drag and drop from toolbox

Question 10 :

If I have more than one version of one assemblies, then how will I use old version in my application? Give an example.

Answer :

Change the assembly version number in the AssemblyInfo.vb file

Question 11 :

How does you handle this COM components developed in other programming languages in .NET?

Answer :

add the component in add reference window, click .NETCOM tab.

While adding the refferences we can handle the COM components in other .Net programming languages.

Question 12 :

How will you register COM+ services?

Answer :

Through X-Copy Deployment.

Question 13 :

What are the different types of replication? How are they used?

Answer :

Replication is used for distributing data and the execution of stored procedures across an enterprise. The replication technology allows you to make duplicate copies of your data, move those copies to different locations, and synchronize the data automatically so that all copies have the same data values.
The different types of replications are
a) transactional replication
b) merge replication

Question 14 :

How do SQL Server 2000 and XML linked? What is SQL Server agent?

Answer :

Every Request or the Response to or from SQL Server is converted into XML format. Its purpose is to ease the implementation of tasks for the DBA, with its full-function scheduling engine, which allows you to schedule your own jobs and scripts.

Question 15 :

Which of the following languages is NOT included in the default .NET Framework installation?
* C#
* JScript.NET
* VBScript.NET

Answer :


Question 16 :

What are the different types of serialization supported in .NET Framework
* XmlSerializer
* SoapFormatter
* XPathNavigator
* HttpFormatter

Answer :


Question 17 :

The CLR uses which format for assembly version numbers
* Major:Minor:Revision:Build
* Major:Build:Minor:Revision
* Major:Revision:Minor:Build
* Major:Minor:Build:Revision

Answer :


Question 18 :

What tool is used to manage the GAC?
* GacMgr.exe
* GacSvr32.exe
* GacUtil.exe
* RegSvr.exe

Answer :


Question 19 :

State True or False: A single .NET dll can contain unlimited classes
* True
* False

Answer :


Question 20 :

State True or False: ASP.NET can currently run only on Windows Platform
* True
* False

Answer :


Question 21 :

Which one of the following best describes "Type-Safe"
* It ensures that the data type are safely handled
* It ensures that types are not mismatched when they are called so uses a typecasting before referencing any data object
* It ensures that an object only references memory locations that it's allowed to, preventing data corruption and the accidental misuse of object types
* All of the above

Answer :

All of the above

Question 22 :

The number of objects in ASP.NET is
* 6
* 7
* 9
* 10

Answer :



Question 23 :

The code used to turn off buffering is
* Buffering = false
* OutputBuffer = false
* BufferOutput = false
* Buffer = Off

Answer :



Question 24 :

Can you have two applications on the same machine one which is using .NET Framework 1.1 and the other using 2.0 ?
* Yes
* No
* Depends on System configuration

Answer :


Question 25 :

Which of the following DOT.NET tools manages certificates, certificate trust lists (CTLs), and certificate revocation lists (CRLs)?
* sn.exe
* certnet.exe
* certmgr.exe
* gacutil.exe

Answer :


Question 26 :

You need to generate a public/private key pair for using in creating a shared assembly. Given the above scenario, which .NET SDK utility should be used?
* certmgr.exe
* gacutil.exe
* sn.exe
* resgen.exe

Answer :


Question 27 :

The object that contains all the properties and methods for every ASP.NET page, that is built is
* Page Object
* HTTPPage Object
* WebPage Object
* System.Web.UI.Page

Answer :

Page Object

Question 28 :

In C#, which character is used to indicate a verbatim string literal?
* @
* !
* "
* #

Answer :


Question 29 :

Which of the following operators has the highest precedence?
* Pre Increment (++x)
* Shift bits left: <<
* Bitwise Or: |
* Post Increment (x++)

Answer :

Shift bits left

Question 30 :

The uniqueId that gets generated at the start of the Session is stored in
* Client computer as a cookie
* Server machine
* Passed to and fro on each and every request and response
* Both a and b are correct

Answer :

Both a and b are correct

Question 31 :

State True or False: C# supports multiple-inheritance
* True
* False

Answer :


Question 32 :

Bitwise AND operator in C# is
* &
* &&

Answer :



Question 33 :

Bitwise OR operator in C# is
* OR
* ||
* |

Answer :



Question 34 :

What's the .NET datatype that allows the retrieval of data by a unique key?
* Primary
* Integer
* Unique Identifier
* HashTable

Answer :


Question 35 :

The keyword 'int' maps to one of the following .NET types
* System.Int16
* System.Int32
* System.Int64
* System.Int128

Answer :


Question 36 :

What can be achieved in IL which is not possible in C# ?
* Creation of an ArrayList
* Creation of a Dictionary
* Creation of a two dimensional array
* Creation of a non-zero based array

Answer :

Creation of a dictionary

Creation of a non-zero based array

Question 37 :

Which of the following is the correct code for setting a Session timeout of 30 minutes
* Session.Timeout = 108000
* Session.Timeout = 1800
* Session.Timeout = 300
* Session.Timeout = 30

Answer :

Session.Timeout = 1800

Session.Timeout = 30

Question 38 :

The process that ASP.NET uses to keep track of Sessions without cookies is
* Cookie Munging
* Cookie Monking
* Cookie Mocking
* Cookie Munching

Answer :

Cookie munging

Question 39 :

The method that transfers ASP.NET execution to another page, but returns to the original page when it is done is
* Server.Transfer()
* Server.Redirect()
* Server.Execute()
* Server.Return()

Answer :



Question 40 :

A structure in C# can be derived from one or more
* class
* interface
* both
* none

Answer :


Question 41 :

State True or False: Static method cannot be overridden
* True
* False

Answer :


Question 42 :

The Equivalent HTML Control for the <input type="button"> tag is
* HtmlInput
* HtmlButton
* HtmlPushButton
* HtmlInputButton

Answer :


Question 43 :

The Equivalent Html Control for the '< input type = " checkbox ">' tag is
* HtmlCheckBox
* HtmlInputChkBox
* HtmlInputCheckBox
* HtmlInputTypeChkBox

Answer :


Question 44 :

Which operator is used for connecting a event with a procedure in C#?
* +=
* =
* both
* none

Answer :


Question 45 :

The Equivalent HTML Control for the <input type="button"> tag is
* HtmlInput
* HtmlButton
* HtmlPushButton
* HtmlInputButton

Answer :


Question 46 :

State True or False: Events in Web forms are processed before the "Page Load" event
* True
* False

Answer :


Question 47 :

What namespaces are necessary to create a localized application?
* System.Globalization
* System.Globalization and System.Resources.
* System.Resources.
* System.Array

Answer :


Question 48 :

A new server-side control can be created by implementing the class
* System.Web.WebControl
* System.Web.UI.WebControl
* System.Web.UI.WebControls.WebControl
* Any one of the above

Answer :


Question 49 :

The parameter "clienttarget = downlevel" does one of the following
* Adds aliases for specific user agents to an internal collection of user agent aliases
* Indicates the useragents level of validating the controls
* Disables all DHTML events(including Validation controls)
* None of the above

Answer :

None of the above

Question 50 :

The methods in C# can be overloaded in which of the following ways
* By having the same method name and specifying different number of parameters
* By giving different method names and same number of parameters
* By having the same method name and specifying different types of parameters
* By giving different method names and same types of parameters

Answer :

By having the same method name and specifying different types of parameters