PRN292_4

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

System.Delegate

A delegate is a class derived from _________

Try Finally

Console.WriteLine("try");

0.0m

For decimal, the default value is

no

Static constructor has _______ parameter/s.

Redirect, Response

The ... method of the ... object is used to redirect the user to another page.

default constructor

The constructor without parameters is called _________.

.dll

The extension of an assembly is _________

All of the above

To add a custom control to a Web form we have to register with

public Font(string fontname, float size

To create an instance of the Font class using existing Font and FontStyle, the constructor is

System.Web.Service

To declare a web service the class must inherit from __________

DataRow array = datatable.Rows[i].ItemArray;

To get values of the columns of the i-th row in a DataTable object named datatable

That object is a newly allocated object and has never been marked for collection.

To help optimize the garbage collection process, each object in the heap is assigned to a specific generation. If an object is marked as Generation 0, it means:

Cmd.ExecuteNonQuery()

To perform a change to a table using the Command object named Cmd, what statement of the following correct?

SolutionExplorer + Tabbed + Class View + Command + Properties Window

To preserve screen space on the monitor , VS.NET provides us with

Command, Solution, Auto-Hide,Properties

To preserve screen space on the monitor, VS.NET provides us with

Command Window va Solution Explorer Window va Auto-Hide Window va Properties Window

To preserve screen space on the monitor, VS.NET provides us with (Choose all answers) Note

Convert an object to a value type

Unboxing is

Manages memory va Compile once and run on any CPU & OS that supports the runtime.

What is the role of the CLR (Select all that apply)

RadioName

in Webfrom, the ... property of the RadioButton control restricts the user to select only one option from given set of options

repeater

select the control which dose not have any visible interface

01234

student s = new student()

menustrip

the___control is used to display text when the mouse points to a particular control

false

thread is executed when we create a new instance of a thread object

HTML

when an .ASPX page is request from the web server, the output will be rendered to Brower in following format

ErrorImage

you are developing a Winfrom application. you have recived instructions to make sure that the PictureBox will

delegate int Met42(int i)

you need to define a delegate for the following method

oledataadapter

you need to get access to an microsoft excel 2003 file. which data adapter would you use?

checkbox

you want to add a control to your form that allows you to set a particular option on or off. which control would you choose?

System.IO

16. Which of these namespaces used for FileAccess

< Select >

<asp:dropdownlist> tag replaces which of the HTML tags

Console,System

Basic input and output operations are performed in C# using the methods of the ______ class in the _________namespace.

TextureBrush va SolidBrush va LinearGradientBrush

Brushes can be created using one of the following classe(Choose all correct answers)

IdataReader

Select the Interface which provides Fast, connected forward-only access to data

System.Web.UI.Page.Culture

Where do you store the information about the user locale ?

System.Data

Which one of the following namespaces contains the definition for IdbConnection ?

Yes, by using FormClosing event

can we cancel closing a form

array1

list<int> array1 = new list<int>()

[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1,

(line 12), if you want to build an in-house XML

Compilation error at line 7.

1. public class Test {2. void show() {3. System.Console.WriteLine("non-static method in Test");4.}5.}6.public class Q3:Test {7.static override void show() {8.System.Console.WriteLine("Overridden non-static method inQ3");9.}10. public static void Main() {a.Q3 a = new Q3();11. }}

True

A C# class can be inherited from multi interfaces?

NO

A C# class can be inherited from multi other classes

False

A C# program can have only one using directive

FALSE

A DataSet object is one of the components of the data provider

False

A DataSet object is one of the components of the data provider.

abstract class

A __ can be thought as a mould of a class.

FORM ACTION="actiopage.aspx" RUNAT="server" method="post"

15. How do you post the current page to a different aspx page ?

No

18. Can a dll run as stand alone application ?

SOAP

22. What is the transport protocol used to call a webservice

Response.Output.Write() allows you to write formatted output

24. What's the difference between Response.Write() andResponse.Output.Write()?

2008

Determine the output of the following code segment: int x = 2009; int y = 2010; System.Console.WriteLine("The value of x & y is : {0}", (x&y));

A common runtime engine

An engine that shared by all .NET-aware languages is called

IAsyncResult

An object that supports the ____ interface stores state information for an asynchronous operation, and provides a synchronization object to allow threads to be signaled when the operation completes.

return types of each method va parameters used by each method

For defining the delegate which of the following entities must be specified?

a nested namespaces

For multiple levels of organizations ___ can be used.

Scripting is separated from the HTML, Code is compiled as a DLL, the DLLs can be executed on server

How ASP.Net Different from ASP?

We can use the property IsChanged to check whether a datatable is changed or not

How can we check that some changes have been made to a DataTable since it was loaded?

By using the System.Activator.CreateInstance() method tocreate an instance of object in the following manner.Type=Type.GetTypeFromProgID("MyDll.MyOName")object myObject = System.Activator.CreatInstance(myObjectType)

How can we create the object dynamically in C#?

Use virtual keyword.

How can we define an overridden base method?

we can use the AcceptChanges method to save all data from Dataset

How can we save all data from dataset?

bool[] b=new bool[3]; va bool[] b={true,true,true};

How can you initialize an array of three Boolean values?

Using SQLDataAdapter

How do we Delete, Update, Select data in a Dataset ?

Use StreamWriter class. Use CreateText() method of FileInfo class.

How do we create a new text file? (choose 2)

Define a pair of accessor and mulator methods va Define a named property

How do we implement encapsulation? (choose 2)

Set the inherits property to codeb

How do you disable client side validation ?

All of the above

How do you manage states in asp.net application?

All of the above

How do you manage states in asp.net applicationSkill/Topic: Intermediate

Add Src, Tagprefix, Tagname

How do you register a user control?

Can not be done

How do you trace the application_End event on runtime?

In Web.config file set the tag to false

How do you turn off the Session state for a webform ?

Session, Application

How many Page directives an ASP.NET page can include

One

How many configuration files can an ASP.NET projects have?

2

How many times the .NET programs are compiled

Only 1.

How many web.config files an ASP.NET application can have

Use different datareader and connection variable

How to open more than one datareader at a time ?

Use DataBound Fields

How to use a checkbox in a data grid(in WebFroms)?

csc /out:< executable name > /target:exe /r:<assembly name1;assemblyname2...;> <filename1 filename2..>

Identify the correct syntax for creating an executable file referencing an assembly.

csc /out:< executable name >/target:exe<filename1 filename2..>

Identify the correct syntax for creating an executable file.

Child c1=new Parent();

If Parent is a base class and Child is its derived class then which of the following statements is not valid?

False

If maximize and minimize buttons are displayed then the HelpButton property is ignored

the assembly is incompatible with previous versions of that assembly.

If there is a change in the major number or minor number of the version number it indicates that _______

8

If you ran the following program what lines would be included in its output?int var1,var2;for(var1=0,var2=0;var1+var2<20;++var1,var2+=1){Console.WriteLine(var1+var2);}

010

If you run the following program what lines would be included in its output?class A{public static void Main (){int i=0;switch (i) {default:System.Console.Write (i);break;case 1:System.Console.Write ("{0}",1);goto default;case 0:System.Console.Write ("{0}",0);goto case 1;}}}

Alpha.Method and Beta.Method can call each other only if Alpha and Beta are located in the same assembly.

Imagine that you have two .cs files. The alpha.cs file contains a class called Alpha that contains an internal method called Method. The beta.cs file contains a class called Beta that also contains an internal method called Method. Can Alpha.Method be called from Beta.Method and vice versa?

Session, Application

In ASP.NET application, and ________ variables can be accessed by all the pages in the application

Value types and reference types

In C# datatypes are divided into two fundamental categories

False

Item stored in ViewState exist for the life of the current page?

No

By default can we delete a folder that contains subdirectories and files

system.dll

By default the compiler opens _____assembly.

using System.Data.SqlClient;

For using SQL.NET Data Provider what using statement of the following is correct?

System.Drawing

GDI + resides in _____ assembly.

504

Given the following code segment, what will the value returned from the method be? public int ViktorMove()

Provides Location Transparency(Distributed Architecture) va Fully Language Independent va Supports version compatibility

List the advantages of DCOM (Choose all correct answers)

Services snd specifications

List the key elements of COM

A set of services for creating and exposing the classes va A set of specifications defining the programming protocol

List the key elements of COM (choose all correct answers)

Nothing

List<int> array1 = new List<int>(); foreach (int n in array1) System.Console.WriteLine(array1.ToString());

False

Manual memory management needs to be done in C#

specifying different number of parameters va specifying different types of parameters

Methods can be overloaded in C# by:

Visual Studio .NET va 3rd party .NET services va .NET platform itself

Microsoft .NET is primarily made up of the following three components.

NGWS (Next Generation Windows Services)

Microsoft .Net was formerly known as __________

ODBC.NET, OLEDB, ORACLE Framework

Name the .NET data providers which are available is VS.NET

ODBC.NET Framework Data Provider va OLEDB.NET Framework Data Provider va Oracle.NET Framework Data Provider

Name the .NET data providers which are available is VS.NET?(Choose all correct answers)

Color property ControlToValidate property

Name two properties common in every validation control?

Using

Namespaces are defined using _____ statements.

Managed code va Unmanaged code

C# code can be classified into types:

purely Object-Oriented

C# is a ____________language.

C++ va C

C# is considered as a modern replacement for the language/s like (Choose all that apply)

No pointers required: Automatic memory management through garbage collection!

C# language offers the following features

Object

C# provides an Unified Type System, which means that all data types are derived from __________ class.

Yes. we can connect to SQL Server Database using OleDbConnection

Can we connect to SQL Server Database without using SqIConnection

Yes. we can connect to SQL Server Database using OleDbConnection.

Can we connect to SQL Server Database without using SqIConnection?

Illegal at compile time

Given these class definitions:class Superclass { }class Subclass1 extends Superclass { }and these objects:Superclass a = new Superclass();Subclass1 b = new Subclass1();which of the following explains the result of the statement:b = a;Select the correct statement.

The code does not compile because static method cannot access nonstatic variables Var1 and var2.

Class Book{int num1=1;int num2;public static void Main(){int num3=3;Console.WriteLine(num1+num2+num3r);}}

Calendar va Dynamic delivery va Notification

Core Microsoft .NET building block services

System.Web.UI.Customcontrols.Webcontrol

Custom Controls are derived from which of the classes

The Exception Type.

A catch clause may catch exception of which type?

sn.exe

A key pair is created using the _______utility.

Compile error!

Determine the output of the following code segment System.Console.Writeline("The value of x/y is: {0}".z);

-1

System.Data.SqlClient.SqlCommand cmd = cn.CreateCommand(); string query = "Select * From Customers";

Nothing

System.Data.SqlClient.SqlConnection cn = new System.Data.SqlClient.SqlConnection();

Namespace

System.Windows.Forms is an important____of the class libraries in .NET framework

Merge Modules

The ____feature of Windows Installer provider a standard method for distributing components and ensures that the installed component is of the correct version.

IsMdiChild

The ____property of the Form control is used to determine whether there are any MDI child forms open in your MDI application

<Script>

The best way to delimit ASP.Net code from HTML code in your pages is by using --------------- tags.

Webforms

Postback occurs in which of the following forms

same as return type of get method of a property.

Return type of indexers is

Statement II is true.

Statement I: Indexers should be used only in situations where the abstraction makes sense.Statement II: Indexers should have both a getter and setter, as arrays are read/write objects.

Only statement II is true.

Statement I: The new modifier is only permitted on delegates declared within another typeStatement II: The new modifier applied on delegate overrides the method for which the delegate is being used.Statement III: The new modifier applied on delegates hides inherited member by the same name.Which of the above statements are true.

Both the statements are true.

Statement I: The sealed modifiers are not permitted in an enum declaration.Statement II: Delegate types are implicitly sealed

if file "Text.txt" does not exist, this code will create a new file

StreamWriter sw = new StreamWriter("Text.txt")

Output of this code is "Nguyen Van A".

Study the following code and choose one correct sentence. using System: class Human { string name: public string Name { get {return name;} set { name = value;} } } class Program { static void MainO { Human h = new Human(); h.Name = "Nguyen Van A"; Console.WriteLine(h.Name); } }

>2

int myVar=3;if (myVar<5)if(myVar<3)Console.WriteLine("<3");else if (myVar>2)Console.WriteLine(">2");else Console.WriteLine("Other");What will appear on the standard output?

catch | finally

int n2 = 0;

1

int number1 = 3;

Form

is the easiest way to allow the user to interact with the application

Is Post Back

it is possible to check whether an ASPX page is posted back to server with the help of the ... property of the page

The output of code will be: The type of objA is : Space1.A

namespace Space1 {using System;public class A{public static void Main() {A objA=new A();Type t1 = objA.GetType();Console.WriteLine("The type of objA is : {0} ", t1);}}}What will be the output of above code when compiled/run?

College.Library.Shelf.Book()

namespace College.Library{namespace Shelf{class Book{ }}}The fully qualified name of class Book is:

Space1.Space2.MyClass()

namespace Space1{namespace Space2{class MyClass{ }}}The fully qualified name of class MyClass is :

is an instance method declaration includes an override modifier

override method

True string strSQL

The code has a compile error

Base class

The library provides shelter from the complexities of raw API calls and offers a consistent object model used by all .NET-aware languages

describes how the elements in assembly are related to each other. va describes the other assemblies on which the elements of the assembly are dependent.

The manifest contains data that ___

Hide

The method ___ of the Control class conceals the control from the user

DrawRetangle

The method can be used to draw a rectangle or a square depending on the coordinates passed as its argument

new

The method that overrides a method in the base class must be prefixed with the ____ keyword.

Visible

The method____of the Control class conceals the control from the user.

b.m2(); va i=b.x; va i=b.y;

Which statements on the <<< call >>> line are valid expressions?public class SuperClass {public int x;public int y;public SuperClass(){}}public class SubClass : SuperClass {private float f;public void m2() {return;}public SubClass() {}}public class T {public static void Main() {int i;float g;SubClass b = new SubClass( );<<< call >>>} }

Source code

Which thing is not included in a .NET PE file

Monitor

Which type of the System. Threading namespace can be used to resolve the issue of concurrency

Application

Which variables can use by all users and in all pages?

A Single session

Who can access Session state variables ?

When using Thread pool, we can focus on our business problem rather than the application's threading infrastructure. va The Thread pool manages thread efficiently by minimizing the number of threads that must be created, started and stopped

Why do we use Thread pool? (choose 2)

WebServices

Why do we use XMLSerializer class ?

The dataset has not been populated.

Why does the data not display using the following code? studentConnection.OpenO: studentCommand = studentConnection.CreateCommand(); studentCommand.CommandType = CommandType.Text studentCommand.CommandText = "SELECT * FROM Student"; studentAdapter = new SqIDataAdapter (studentCommand): studentSet = new DataSetO; this.txtFirstName.DataBindings.Add ("Text". studentSet "FirstName");

To implement application & Session level events

Why is Global.asax is used for ?

Don't have integrated connection for the command object.

Why the data is not inserted using the following code? SqlCommand insertConmmand = new SqlCommand(); insertCommand.CommandType = CommandType.Text;

explicit

Unboxing requires an ___________cast.

SoapFormatter

You are required to build an application that can serialize an object to a file. Then, this file can be transferred to another program written in Java and running in Linux operating system to be de serialized Which of the following classes is the best choice for the above task?

delegate int Met42(int i);

You need to define a delegate for the following method: public class Classl { public static int Method42(int i) { return i*42; } }

SqIDataAdapter

You need to get access to a database that is stored on a server running Microsoft SQL Server 2000. Which data adapter would you use?

OleDdDataAdapter

You need to get access to an Microsoft Excel 2003 file. Which data adapter would you see?

Control Anchoring | control docking

___ are the visual effects supported in winforms

Event

___ is any action directed at the application

Windows application

___ is he normal output type for a Windows Forms project

datasource

___ property is used to get or set the data source that the gridview is displaying data for

PrintPreviewControl va PrintDocument

____ are the Print support controls provided by WinForms.(Choose all correct answers)

using

_____ keyword is used to import the classes of the namespace

virtual

_______ enables the possibility for a function to be polymorphic when it is overridden in one or more inherited classes.

An Event

_______ is a member that enables an object or class to provide notifications.

Personalization

_______ service allows users to handle their own rules for handling messages and notifications.

Orchestration

________ allows developers and business analysts work together to define and modify business processes shared between applications.

An Assembly

________ is a unit of class deployment.

Boxing

__________in simple terms is nothing but conversion of a value type into a reference type.

Unboxing

__________is all about converting a reference type into a value type.

Anchor

_____property is used to get or set the edges of the control are anchored to the edges of its container.

CLR

Under which of the following environments dose your programs execution code run?

Class libraries

____are the collection of reusable classes or types

Visual Inheritance va Visual Inheritance va Cotrol Docking va Transparent Forms

____are the visual effects supported in WinForms (Choose all correct answers).

ComboBox

____control combines the features of the TextBox and the ListBox controls

Value

____property is used to get or set the object that contains data about the control

PopUpMenu

____property is used to get or set the shortcut menu associated with the control.

ConnectionString

____property of a connection object is used to get or set the string used to open a database

data can be stored using value types but not in the reference type. va Variables of the value types directly contain their data, whereas variables of the reference types store references to objects.

Value types differ from reference types as___

application va session

Variable can be accessed by all the pages in the application (choose 2 answer)

<Major version>.< Minor version >.<Revision>.<Build Number>

Version number of an assembly are stored in the following format:

No

We CANNOT use methods that have some arguments for a delegate?

BinaryFormater, SoapFormater and XMLSerializer.

What are formatters you can choose when serialization an object?

Description, MessageName and EnableSession.

What are properties of [WebMethod] attribute?

Description. Name and Namespace.

What are properties of [WebService] attribute

IIS Admin and World Wide Web Publishing

What are required services in an ASP.NET Web server

Loading the type into memory and compiling CIL into platform-specific instruction.

What are responsibilities of CLR?

Checked Only

What are states that a CheckBox can have

Modeless , Modal

What are the types of Dialog boxes

Modeless dialog boxes va Modal dialog boxes

What are the types of Dialog boxes?(choose all correct answers)

Invoke Show

What are thee steps involved involved in calling one from another form

public static void Main() { }

What can be signature of an application's entry point

ListView

What control support us to display the list items in different types as text only, text with small icons, text with large icons and report views?

All of the above

What data types do a Rangevalidator supports?

It will stop the server process

What does Response.End will do?

It allows the page to save the users input on a form across postbacks.

What does the "EnableViewState" property do?

The method can be overridden.

What does the keyword "virtual" declare for a method?

No constructor matching SuperClass() found in class SuperClass

What error does the following code generate?//No overload for method 'SuperClass' takes '0' argumentspublic class SuperClass {SuperClass(string s) { }}public class SubClass : SuperClass {SubClass(string s) { }public static void Main(){SuperClass s = new SubClass( "The" );}}

'Class.getNumber()' must declare a body because it is not marked abstract.

What error does the following code generates when compiled?1.abstract class Class2.{3.public void getNumber();4.}5.class ClassA:Class6.{}

.DLL

What executable unit gets created when we build an ASP.Net application?

VB.NET

What is NOT a client-site technology

SoapFormatter is a serialization formatter that represents graph as a SOAP message

What is SoapFormatter

The one which renders the dataset object contents to XML

What is a diffgram ?

An Assembly containing localized resources for another assembly

What is a satallite assembly ?

Combination Of both Public,Private key and digital signature

What is a strong name?

MySQL

What is a third-party data provider

It is possible to have designers working on the markup while programmers author the C# code.

What is advantage of code-behind page model

Internal

What is default accessibility for the structures in C#?

Set of resource, such as external code libraries and the primary thread | Necessary memory allocations used by a running application

What is described in "Win32 process " term? (choose 2)

Get Post

What is method of form to transmit the form data back to web server for processing

My Webservice

What is name of this web service? [WebService(Namespace = "http://tempuri.org/", Name-'My Webservice")] [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)] [System.ComponentModel.Toolboxltem(false)] public class WebServicel : System.Web.Services.WebService { [WebMethod] public string HelloWorld() { return "Hello World"; } }

Nothing

What is output of the following code? List<int> arrayl = new List<int>0; breach (int n in arrayl ) System.Console.WriteLine(arrayl.ToStririgO):

The abstract member cannot be private.

abstract class Class{private abstract void getNumber();}class ClassA:Class{ }What error does the following code generates when compiled?

Implement the methods getNumber(),getHeight(), getWidth() in the class ClassB.

abstract class Class{public abstract void getNumber();public abstract void getHeight();public bool isEmpty(){return (true);}}abstract class ClassA:Class{public abstract void getWidth();}class ClassB:ClassA{ }What changes should be done in the above code so that the code does not generate any error at compile time?

try finally

What is output of the following code? using System: class Program { static void MainO { try Console.WriteLine("try"); catch Console.WriteLine("catch"); finally Console.WriteLine("finally"); }

Mammal

What is output of the following code? using System: interface Animal { void DisplayO; } class Mammal: Animal { public void DisplayO { Console.WriteLine("Mammal"); } } class Program { static void MainO { Animal a = new Mammal(); a.DisplayO: } }

0

What is output of the following code? using System: using System.Data: class Program { static void MainO { DataTable dt = new DataTableO; Console.WriteLine(dtColumns.Count); }

1

What is output of this code? Static void Main(){ int number1 = 3; int number2 = 2; float number3 = number1/number2;...

VISUAL C

What is output of this code? string s1 ="Visual C# And .NET Technology"; string s2 = s1.Substring(0, s1.IndexOf('#')); System.Console.WriteLine(s2.ToUpper());

Hello world!

What is output when request the page that contains the code bellow? protected void Page_Load(object sender, EventArgs e){ Response.Write("<h1>Hello world!</h1>"); }

Marks a member as accessible only by the class or any derived classes.

What is protected access modifier?

Return records that have StudentNo, LastName, FirstName from Students table and ClassName from Classes table

What is result of the following SQL command?Select Students.StudentNo, Students.LastName, Students.FirstName, Classes.ClassNameFrom Students Inner Join Classes On Students.ClassID = Classes.ClassID

return the physical file path that corresponds to virtual specified path

What is significance of Server.MapPath?

DomainUpDown, NumericUpDown

What is spin control

Unstarted

What is state of a thread after creating a Thread object

Unboxing

What is term for conversion from an object to a value type?

Web Service Description Language

What is the Full Form of WSDL ?

Gets the Server's Machine Name

What is the Server.MachineName does ?

The TrackBar control allows user to select a value from a range (of values), using scroll bar-like input mechanism.

What is the TrackBar control

User data can update and retrieve in dataset and when connection connected, update values with server

What is the advantage of Disconnected mode of ADO.Net in ASP.Net ?

The base keyword is used to access members of a base class from within a derived class

What is the base keyword

/*... */

What is the correct syntax for comment entries in C#

Anonymous

What is the default authentication mode for IIS ?

20 Min

What is the default session time out?

Httphandler is an class and Httpmodule is an assembly

What is the difference between HTTP handlers & HTTP modules ?

Response.Redirect needs roundtrip, Server.Transfer does not

What is the difference between Server.Transfer & Response.Redirect ?

.Ascx

What is the extension of a web user control file ?

Load

What is the first event is raised when the form has been allocated on the managed heap

Define a delegate that contains the method to be called when the event is fired.

What is the first step to define an event?

20

What is the maximum number of cookies that can be allowed to a web site ?

C

What is the out put of Following code : String a="Hello"; String b="World" ; String c= a+b ; Response.Write ( "C");

300

What is the out put of the following code : byte a=200; byte b=100; byte c=a+b; Response.Write ( C );

Compile Time error

What is the out put of the following codebyte a=200;byte b=10.0;byte c=a+b;Response.Write ( C );Skill/Topic: Advanced

Test(1)Test(3)Test(2)

What is the output of the following code?public Test(int i){System.Console.WriteLine("Test(" +i +")");}}public class Q12{static Test t1 = new Test(1);Test t2 = new Test(2);static Test t3 = new Test(3);public static void Main(){Q12 Q = new Q12();}}

AutoPostBack

What is the property of ASP.NET DropDownList control can make change events cause a postback?

For Reading metadata at runtime

What is the purpose of Reflection?

To separate HTML Layout and code to different file

What is the purpose of code behind ?

The DataAdapter will create 3 data tables in the dataset.

What is the result of the following code? SqlConnection conn = new SqlConnection(); conn.ConnectionString = CONNECTION_STRING;

Adds HTTP Headers to output stream

What is the significance of Response.AddHeaders( ) ?

Unboxing is conversion from a value type to an object.

What is unboxing?

Solution Explorer

What is utility allows you to view the set of all content files and referenced assemblies?

Object Browser.

What is utility shows all of the types in your current project from an object-oriented perspective?

It uses more than one loop index.

What is wrong with the following for statement?for(i=0;j=0, i<10; ++i,j+=i){k+=i*j+j*j;}

Stack area

What kind of memory where an object is allocated

Both Debug Mode and Release Mode

What mode is VS.NET allow you create a portable exe(EXE) file

Debug Mode

What mode is VS.NET allow you to step through each line of code and trace the execution of your application

System.web.UI.Page

What namespace does the Web page belong in the .NET Framework class hierarchy?

AChild.MdiParent = TheParent;

What of the folllowings is correct if we want to set the Achild form as a child

AChild.MdiParent = TheParent;

What of the folllowings is correct if we want to set the Achild form as a child form of the parent form named TheParent

SqlConnection con = new SqlConnection("Data Source=myserver;Integrated Sercurity=SSPI; Initial Catalog=MyDB");

What of the following are correct for creating a connection object to database named MyDB? (Choose all correct answers)

Form Control and Field

What of the followings are data validation mode in WinForms

Form-Level Validation va Control-Level Validation va Control-Level Validation

What of the followings are data validation mode in WinForms?(Choose all correct answers)

Select * From Student", con

What of the followings is correct for creating a command object with the connection con

After the webform loads

When is the user controls code is executed ?

the number of items in the initialization list. va The number present in the square bracket next to the data type at the right hand side.

When the array is initialized at the same time they are created, the c# compiler determines the size of array using ________

Hashtable

When we want to associate a key with values which of the following classes are preferred?

When the application is low on memory

When will the garbage collector run?

The Application tab of the project's Properties window.

Where can you change 'Default Namespace" of Visual Studio

InProcess

Where is the default Session data is stored in ASP.Net?

SQLISAPI.dll

Which DLL translate XML to SQL in IIS ?

All of the above

Which Language can Support SOAP ?

System.Object

Which class is at the top of.NET class hierarchy?

DataTable

Which class is used to insert, remove, evaluate and manipulate the values in a table of one DataSet

ContextMenu

Which class represents shortcut menus that can be displayed when the user clicks the right mouse button over a control or area of the form

ToolTip

Which control is used to display a short, customized help message for individual

ToolTip

Which control is used to display a short, customized help message for individual controls on a form?

Datagrid

Which control supports paging ?

System.Threading namespace does not contain this delegate.

Which delegate of System.Threading namespace points to any methods that

In lib.dll

Which delegate of System.Threading namespace points to any methods that take no argument and returns int?

KeyDown

Which event of form handles pressing a key

Name of machine, name of the database on that machine, required

Which information is included in a connection string

Marks a member as accessible limited to the current assembly, but not outside the assembly

Which is internal access modifier

An integer is number of affected rows

Which is return value of ExecuteNonQuery() method of a Command object

This

Which keyword is used when you wish to explicitly reference the fields and members of

sealed

Which keyword prevents your class from being inherited by another class?

Background threads

Which kind of threads is automatically killed when the application domain unloads?

ThreadPriority

Which member of System.Threading namespace is an enumeration

Render

Which method displays the custom control ?

Fill ( )

Which method do you invoke on the Data Adapter control to load your generated dataset?

UnLoad()

Which method is fired lastly during the page load

System.Web.Security

Which namespace allows us to formauthentication ?

System.Windows.Forms

Which namespace does the class ListView belong to

System.Web.Mail

Which namespace is VS.NET contains classes that help in constructing and sending emails

DataRelation

Which objects is used to create foreign key between tables?

asmx

Which of following extension does a Web service file will have?

public abstract class ClassA

Which of the following are correct statements for implementing an abstract class.

Open

Which of the following are not a member of Server Object ?

It is always executed unless its thread terminates

Which of the following are true about the finally clause of try-catch-finally statements?

For static methods, a callable entity consists of just a method. va Delegate types are implicitly sealed va It is not permissible to derive any type from a delegate type.

Which of the following are true with respect to delegates?

@void va _void va _var

Which of the following are valid identifiers?

Struct va Union

Which of the following are value types?

catch{}finally{}

Which of the following associations of try, catch and finally is INVALID?

Structures, Delegate,Methods,Classes...

Which of the following can be defined as generic

All of the others

Which of the following can be defined as generic? (Choose one answer)

csc /out:myAssembly.dll /target:library file1.cs file2.cs

Which of the following commands can be used to create assembly named "myAssembly" from the files "file1.cs and file2.cs"?

public event MyDelegate MyEvent;

Which of the following is a correct event that is based on the delegate named " MyDelegate"

private delegate int MyDelegate() ; va public delegate void MyDelegate() ;

Which of the following is a correct statement that defines a delegate?

class MyClass

Which of the following is a correct statement to declare the class "MyClass"?

Test() { } va Test(int a, int b){} va public Test(int a, int b){}

Which of the following is a legal constructor for the class Test.

int j=0;for(int k=0;j+k!=10;j++,k++){Console.WriteLine("j= {0} k={1}",j,k);}

Which of the following is a legal loop construction?

public virtual void Display(){}

Which of the following is a valid method declaration?

class A:B

Which of the following is a valid statement to implement class B in the class A.

_Class va @class va Class

Which of the following is a valid variable in C#?

Open

Which of the following is not a member of ADODBCommand object ?

Open

Which of the following is not a member of ConnectionObject ?

Cookies

Which of the following is not a valid state management tool?

3, 1, 2

Which of the following is the correct sequence to handle an event in C# ?1.Subscribe object2.Notify subscriber3.Define an event

protected int this[int var1] va public int this[int var1]

Which of the following is the correct syntax for declaring an indexer.

Custom controls are displayed correctly in VS.Net Designer

Which of the following is true ?

IsPostBack is a readonly property of System.Web.UI.Page class

Which of the following is true ?

Both A and C (C# va Visual Basic)

Which of the following languages can be used to write server side scripting in ASP.NET

Employee (){} va Employee(int empno){}

Which of the following methods can act as a constructor for the class "Employee" that is used to create an object?

Object(){}

Which of the following methods can act as a constructor for the class "Object" that is used to create an object?

public void methodA();

Which of the following methods can be called as an "operation"?

~myClass() { }

Which of the following methods can be used as a destructor for a class "myClass".

It must be assignable to the Exception type.

Which of the following must be true for the object thrown by a throw statement

SQLDataAdapter va OleDbDataAdapter va ADORecordSet

Which of the following objects can we use to read data from a Micorosoft SQL Server 2000 database? (choose all correct answers)

IsCLass va IsPublic va IsCOMObject

Which of the following properties does the Type class have?

The constructor must have the same name as that of the name of its class.

Which of the following sentences are true about Constructors?

Each field in the DataGrid is bound to a single column based on the DataSource va The DataGrid control display data in tabular format and optionally supports data editing

Which of the following statement with respect to Data Grid control are True? (Choose all correct answers)

An explicit interface member implementations can be abstract. va An explicit interface member implementations are permitted to call abstract methods.

Which of the following statements are correct?

A delegate can be thought of as a type-safe object-oriented function pointer. va It can handle only one method at a time. va It cannot be used for event handling.

Which of the following statements are true about delegates

It can be used to effectively find all the types in an assembly and/or dynamically invoke methods in an assembly. va It can at times even be used to emit Intermediate Language code on the fly so that the generated code can be executed directly.

Which of the following statements are true about the Reflection API?

Static constructors cannot take parameters. va Static constructors cannot be called explicitly.

Which of the following statements are true with respect to Static constructors.

A class has no other constructors than those that are actually declared in the class va Constructors are not inherited

Which of the following statements are true with respect to Static constructors?

Because methods are allowed to hide inherited methods, it is possible for a class to contain only one virtual method with the same signature. va For every virtual method inherited by or declared in a class, there exists a most derived mplementation of the method with respect to that class.

Which of the following statements are true with respect to a virtual method

Abstract event declarations are only permitted in abstract classes. va An overriding event declaration must specify the exact same accessibility modifiers, type, and name as the inherited event

Which of the following statements are true with respect to abstract functions?

Yes, by using DrawPolygon method of Graphics object

an we draw a hexagonal with GDI+

An implicit reference conversion exists from any array type to System.Array va The System.Array type is the abstract base type of all array types The members of an array are the members inherited from class System.Array.

Which of the following statements are true with respect to an Array type.

When an instance is destructed, the destructors in an inheritance chain are called in order, from most derived to least derived. va A class has no other destructors than those that are actually declared in the class.

Which of the following statements are true with respect to destructors?

Overloading of methods permits a struct, or interface to declare multiple methods with the same name, provided the signatures of the methods are all unique.

Which of the following statements are true with respect to overloading?

catch statement are examined in order in which they appear .

Which of the following statements are true with respect to try-catch block?

A static constructor is a member that implements the actions required to initialize a class. va A static constructor cannot have accessibility modifiers.

Which of the following statements are true?

Obtains Class and Type Information from an Assembly va Obtains Member Information from a Class va Dynamically Invokes Methods from Classes in an Assembly

Which of the following statements best illustrates the use of the Reflection API.

namespace Namespacename{ ----- ----}

Which of the following statements correctly declares a namespace?

In an interface the method name is fixed, whereas with a delegate only the signature is fixed. and Interface cannot be instantiated but delegates can be instantiated.

Which of the following statements correctly differentiates between delegate and an interface?

the overriding method must return void

Which of the following statements is correct for a method, which is overriding the following method: public void add(int a) {...}Select the most appropriate answer

An object is the instantiation of a class.

Which of the following statements is true?

System built on ADO.NET are intrinsically highly scaleable va When we use the DataSet object, ADO.NET is based on disconnected data access.

Which of the following statements with respect to ADO.Net are True? (Choose all correct answers)

class Object{ static void Main(){} }

Which of the following will execute without errors at compile time.

An instance of a type that is Serializable can be easily transmitted over the network, or stored in a file on the file system

Which of the statements on Serializable is true?

None

Which parameter modifier marks a parameter as passed by value

AcceptButton

Which property of Form allows to set the button on the Form that is clicked when user press the Enter key?

PasswordChar

Which property of TextBox control in Windows Forms application is used to create password input box?

Message

Which property of the Exception class specifiles textual information that indicates the reason for the error and provides possible resolutions?

The CLR is able to load and unload a formal process much quicker than Application Domains.

Which sentence about Application Domain is correct?

BufferedStream provides temporary storage for a stream of bytes that may be committed to storage at a later time.

Which sentence about BufferedStream is correct?

Connection object is used to establish a session with the data source.

Which sentence about Connection object is correct?

A DataSet is an in-memory representation of external data

Which sentence about DataSet is correct

Values of each GUI widget on the page are stored in a hidden form field.

Which sentence about ViewState is correct

WSDL is used to describe information about the web service | WSDL is used to describe information about the web service

Which sentence about WSDL is correct

Foreground threads have the ability to prevent the current application from terminating.

Which sentence about foreground threads is correct?

Classes from many namespaces can reside in one assembly.

Which sentence about namespace is correct?

Private assemblies reside in the same directory of application making use of them.

Which sentence about private assemblies is correct?

Shared assemblies are deployed to GAC.

Which sentence about shared assemblies is correct?

Strong name is used to uniquely identify the publisher of a .NET library

Which sentence about strong name is correct

The thread pool manages threads effciently by minimizing the number of threads that must be created, started, and stopped.

Which sentence about thread pool is correct?

A namespace is a logical compile-time mechanism

Which sentence is correct

An abstract class is a class that cannot be instantiated.

Which sentence is correct?

The code is illegal because of expression at line 4.

Which statement is true about the following code fragment?1. int j=2,a=1;2. switch(j){3. case 2: Console.WriteLine("Two");break;4.case 1+a: Console.WriteLine("Two Two"); break;5.default: Console.WriteLine(j);6.}

The output would be only the text "Two".

Which statement is true about the following code fragment?1. int j=2;2. switch(j){3. case 2: Console.WriteLine("Two");break;4. case 2+1: Console.WriteLine("Three");break;5. default : Console.WriteLine(j);}

output of this code is 0

arraylist arr1 = new arraylist();

no

assume that you create a web service by visual C# language. can you consume this web service by a client that is write in java language?

Title bar

by setting the Text property on the form, you will cause the value of the Textproperty to display on which part of the form?

Yes, by using DrawPolygon method of Graphics object

can we draw a hexagonal with GDI+

yes, we can by setting pooling=true in ADO.NET connection string

can we enable and disable connection pooling?

yes, but methods have to only one argument

can we use methods that have some arguments for a delegate?

yes, by setting value for "runat" property if html controls is "server"

can we work with server-side code on html controls?

The code will compile and run and the letter "A" will be written to the standard output.

char c='a';switch(c ){case 'a': Console.WriteLine("A");break;default: Console.WriteLine("Default");}What will happen if you attempt to compile and run code that includes this snippet?

ViewState persist the values of control | SessionState persist the data of particular user

choose 2 correct statements about the ViewState and SessionState

Server side code is executed at the server side... | client side code is executed on the IIS

choose 2-correct statements about Server-side and Client-Side codes?

a user control has an interface that can be completely edit | a user control is a server-side component that is shipped

choose correct statements about user controls

viewstate

choose the concept that is not related to asp.net security

X=1, Y=2

class A { public static int X = B.Y + 1; }class B { public static int Y = A.X + 1;static void Main() { Console.WriteLine("X = {0}, Y = {1}", A.X, B.Y); } }what will be the output of above code?

defabc

class Class1 { internal string field1; } Class Program { Class1 obj1 = new Class1();

No errors, but there is 1 warning.

class Mammal : Animal public string Name { get; set; }

The code will compile successfully and display following lines on the standard output: Hello Hello Hello

class Question{delegate void Delegate();static void Foo() {System.Console.WriteLine("Hello");}static void Main() {Delegate d = new Delegate(Foo);Question t=new Question();t.MultiCall(d,3);}void MultiCall(Delegate d, int count) {for (int i = 0; i < count; i++)d();}}What will be the output of above code when compiled/run?

The code generates a compile time error the code will compile successfully as the using-namespace-directive does not bring the name Inner itself into scope.

namespace Outer.Inner{class Wibble { }}namespace Test{using Outer.Inner;class SpecialWibble: Inner.Wibble { }}Which of the following statements are true about the above code?

ASCX

custom control created using C# need to be saved using the extension

0

datatable dt = new datatable()

compile error at line: display d1 = new display(displayHello)

delegate void Display();

compile error at line: display d1 = new display(displayHello);

display d1 = new display(displayHello);

2010

display<system.int32>(2010)

i=0 j=1 va i=0 j=2 va i=1 j=0

for(int i=0;i<2;i++){for(int j=0;j<3;j++){if(i==j) continue;}Console.WriteLine("i={0} j={1}",i,j);}Which lines would be the part of output?

we can use the add method of data table class

how can we add a row is in a data table object?

we cannot connect to SQl server database without using SQlconnection

how do we connect to SQL server database without using SQlconnection?

Use TextBox control with PasswordChar property is set a value

how do we create a control to enter password

session.abandon()

how do you explicitly kill a user's session

all of above

how do you manage state in ASP.Net Application

As much as you want

how many classes can a single .NET DLL contain?

set EnableClientScript to false

how to disable client side script in validation control?

focus

in Windows, specify the method to place the focus on the control

SetNextControl

in Winfroms, specify method used to specify the next control to be navigated according to the tab order

linklable

in windows form, ___is a command type control

delegate int Class1.Method42(int i);

public static int Method42(int i)

1,2

select the correct statements about ADO.Net:

calls post method on the test.aspx

select the output of the statement<form method = "post" action = "test.aspx">

event-driven

select the type processing model that ASP.NET simulate

yes, there is an error at line: input(ref s2)

static void input(ref string s1)

No is 02010

student s1 = new student("02010","Nguyen van a");

@cacheOutput

the ... directive is used to set the Caching duration of the output for a page

getdata

the ... object allows us to retrieve & manipulate data in the database

Connection

the ... object allows us to retrieve & manipulate data in the database.

from.get Request object

the ...method of the...object is used to retrieve the data in the form fields submitted by the user

server

the code will be process don web server when the run at attribute of the Script tag has the following value

required field validator

the control is used when a field a field must not be left banal

statement 3 is correct

the deactivate event occurs when the user switches away from the from and concentrates on other from

page.Init

the first event to be triggered in an .ASPX page is

page_init

the first event to be triggered in an .aspx page is

byte

the variable of which type is not signed number?

Register

the...directive is used to consume a created custom control

redirect, response

the...method of the...object is used to redirect the user to another page

DataAdapter

the___component is used to fetch the values from the data source to the DataSet and also to update the data source with the DataSet data

exception 2 finally

try {tryThis();return;} catch (DivideByZeroException x1) {System.Console.WriteLine("exception 1");return;} catch (Exception x2) {System.Console.WriteLine ("exception 2");return;} finally {System.Console.WriteLine ("finally");}What will appear in the standard output if tryThis() throws a 000000000FormatException?Select the one right answer.

catch finally

using System; class Program Console.WriteLine("catch"); Console.WriteLine("finally");

4

using System;class MyClass{int Var1=1; int Var2;public static void Main(){int LocalVar=3;MyClass m1=new MyClass(); Console.WriteLine(m1.Var1+m1.Var2+LocalVar);}}The output of above code will be:

5 va 8

using System;class Question{public static void Main(){for (int i=0;i<10;++i) {try{if(i%3==0) throw new Exception("E0");try{if(i%3==1) throw new Exception("E1");Console.WriteLine(i);}catch (Exception inner){i+=3;}finally {++i;}}//try1catch(Exception outer){i+=3;}finally {++i;}}}}Which of the following lines does the above program display?

The code will display 0.

using System;class Test {static void Main() {int @Main;int[] Static= new int[3];@Main =100*Static[1]; Console.WriteLine(@Main);}}What will be the output of above code?

4 va 5

using System;class Test{public static void Main(){for (int i=0;i<10;++i) {try{try{if(i%3==0) throw new Exception("Exception1");Console.WriteLine(i);}catch (Exception inner){i*=2;if(i%3==0) throw new Exception("Exception2");}finally {++i;}}catch (Exception outer){i+=3;}finally {--i;}}}}

The code will generate a compile time error.

using System;class Test{public static void Main(){int value =Int32.Parse("99953");double dval=Double.Parse("1.3433E+35");Console.WriteLine(value);Console.WriteLine(dval);}};What will be the output of above code when compiled/run?

The output of the code will be: 321123

using System;class Test{static void Main(){int[] Array1= {3,2,1};Display1(Array1);Array.Sort(Array1);Display1(Array1);}static void Display1(Array pArray){foreach(int t in pArray){Console.Write(t);} }}What will be the output of above code?

when the page is posted back...| it save the server-side value...| it allows the page to save...

what dose the "EnableViewState" property do?

omly the matching records from the two tables

what dose the following sql statement return, assuming that all tables and column names are correct?

CLR is a set of rules provided to ensure that products of compilers will work properly in .net

what is CLR?

UDDI is a language is used to describe a xml web service

what is UDDI?

Unified framework for rapidly building service-oriented application

what is WCF?

is used to describe information about web service

what is WSDL?

XML Http request object

what is at the heart of Ajax programming

the process of accepting credentials from a user and validating thoe credentials against a designated authority

what is authentication?

Anonymous

what is default authentication mode for lls?

fasle

what is default value of autoPostback property?

server.execute returns the execution back to the current page, and sever

what is different between server.execute and server.transfer

ASCX

what is extension of a web user control file

it is the code targeting the .NET runtime

what is managed code?

surround with

what is name of templates that wrap a block of selected statements within a relevant scope?

Uses standard Web protocols to communicate

what is not a characteristic of Web Service?

ajax-enable asp.net pages

what is not a component of ASp.net ajax sever framework?

to separate HTML layout and code different file

what is purpose of code behind

datatable dtOrder = new datatable("order");

what is the correct way of creating a data table in a dataset?

server-side technology

what is the kind of asp.net technology?

exit for the life of the current pace

what is the life span for items stored in view state

Microsoft Ajax library

what is the most important component of ASP.NET AJAX Client Framework?

just-in-time (JIT) compiler

what is the name of entity that compiles CIL code into meaningful cpu instruction?

IL

what is the output format of the file the C# compiler produces?

gets the server's machine name

what is the server.machine name does

32 bit long string

what is the size of the SessionID?

managed heap

what kind of memory where an object is allocated?

TheParent.mdiChild = Achild

what of the following is correct if we want to set the AChild form as a child from of the parent form named TheParent?

sqlCommand cmd = new sqlcommand("select * from student", con);

what of the followings is correct for creating a command object with the connection con?

inside tag in asp:Datagrid we set Text attribute to <%#DataBinder.Eval(Container.DataItem, "Col_Name")%>

what tags do you need to add within the asp:datagrid tags to bind colimns manually?

.NET assemblies are versioning, self-descrbing and configurable

which sentence about .NET assemblies is correct?

view state data can be transferred between asp.net web pages

which sentence about Asp.net view state is correct?

an HTML form is a named group of related UI elements used to gather used input

which sentence about HTML form is correct?

background thread are viewed by the CLR as expendable paths of execution

which sentence about background threads is correct?

an example of components is openFileDialog

which sentence about components is correct?

default context is used to group together .NET objects that have no specific or unique contextual needs

which sentence about default context is correct

you cannot change value of a session variable

which sentence about session variables is correct?

shared assemblies are *.dll files only

which sentence about shared assemblies is correct?

C# language dose not full support for interface-based programming techniques

which sentence is correct about C# language?

cannot convert implicitly from integer type to decimal type

which sentence is incorrect?

rangevalidator

which validation control is used to validate that the value of an input control is equal to a fixed constant?

a single session

who can access to sections state variables

false

winform is a class library that enable developers build web application

dsetl.writexml(@"D:\Scores.xml");dataset dset2 = new dataset(); dset2.readxml(@"D:\Scores.xml"); response.write(dset2.getxml());

you want to write the content of a dataset, dsetl, to a file Scores.xml

All of the above

32. How do you manage states in asp.net application

One Custom Control can be use in different project but not the same with User control

33. what is the difference between user control and custom control

SQLPermission

60. The object used by SQL connection to make Security Demands

Compile Time error

84. What is the out put of the following codebyte a=200;byte b=100;byte c=a+b;Response.Write ( C );

Request

96. Client Sertificate is a collection of

4

97. What section of the config.Web file is used for storing a list of authorized users?

2.0

98. What version of the javascript should be used for client side script

ODBC OLEB

ADO.NET provides features for accessing traditional databases like SQL Server

ODBC

ADO.NET provides features for accessing traditional databases like SQL Server as well as databases, which are accessed using ____.(choose all correct answers)

OLEDB + XML

ADO.Net.Provider features for accessing traditional database like SQL Server as well as databases , which are accessed using ___

name of method va Parameters va return type

Abstract methods holds only:

public va private va protected

Access Modifiers for variables in C# can be the following (Select all that apply)

KeyDown, KeyUp, KeyPress

Arrange the sequence in which the key events are triggered

There is nothing wrong with the statement.

Array X and Y have integer data types. If these arrays are initialized properly, what is wrong with the following statement?for(int var=0;var<0;++var){if(x[var]>100) break;if(x[var]<0) continue;x[var+1]=x[var]+y[var];}

The lines 1 and 4

Assume that BaseClass is a class. IFacel and IFace2 is interface Which of the following declarations is INVALID/"Line 1*/ class ImplDerivedClass: IFace2. BaseClass. IFacel { } /"Line 27class ImplClass: IFacel. IFace2 { } /"Line 37 class DerivedClass: BaseClass. IFacel { } /•Line 47 class DerivedClass: IFace2. IFacel. BaseClass { }

Compiles and definitely legal at runtime

Assume that Sub1 and Sub2 are both subclasses of class Super. Given the declarations: Super super = new Super(); Sub1 sub1 = new Sub1();Sub2 sub2 = new Sub2(); Which statement best describes the result of attempting to compile and execute the following statement: super = sub1;

Miss calling the DataBind() method of the page

Assume that a method named DataLoad is defined to makes a list of suppliers available by returning an ICollection interface. A Web page has a ListBox control named IbCustomers. The Page_Load event handler for the Web page contains this code: private void Page_Load(object sender, System.EventArgs e) { IbCustomers. DataSource = DataLoad(); IbCustomers. DataTextField = "CustomerName"; } The Web page opens without error, but no customer names are displayed. What is the problem?

public delegate bool Methodl(string si) ;

Assume that you wish to build a delegate that can point to any method that returns a bool value and takes a string as input parameter. What is corre ct syntax to declare this delegate?

Use the Disconnected Layer

Assume you wish show data of Customers table in a DataGridView control. What is the best manner to do it

RegularExpressionValidator

Assume you wish to check validation of E-mail data. Which validation control is the most suitable to do it

Parameterized

At least one _______ constructor must be declared to suppress the automatic generation of a default constructor.

No

Is it possible edit data in a repeater control

Compile error

System.Console.WriteLine("Hello {0}". yourName):

Compile error

System.Console.WriteLine("Number 1 is 1");

Panel

The ____control groups a set of controls within a non-labeled an scrollable frame

runtime error

console.writeline(dr.hasrows.tostring())

total rows of products table

console.writeline(dt.rows.count.tostring());

all of above

what data types do a range validator supports

stop the server process

what dose response,end will do

Add reference of dll file and place the code where ever required

99. How do you add ASP.Net 3rd party component

DataRow objects

... are used to retrieve values in the DataTable

DataSet

... is an object in which the data retrieved from the database can be stored.

session | server

... variable can be accessed by all the pages in the application

NET Framework class library , Common Language Runtime

.NET Framework has two main components, are

False

.NET is a whole new platform centered around the Intranet

Compilation error at line 3.

1. public class Q21 {2. int maxElements;3. void Q21() {4.maxElements = 100;5.(maxElements);6.}7.Q21(int i) {8.maxElements = i;9.System.out.println(maxElements);10. }[2.5]11. public static void Main() {12. Q21 a = new Q21();13.Q21 b = new Q21(999);14.}15.}

3,2,1

1.Place the assembly in the global assembly cache.2.Sign the assembly with the key pair.3.Create a key pair.Which of the following is a correct sequence to convert a Private assembly to a Shared assembly.

The code will compile successfully and the output of above code will be: Test.F

1.class Test{2.delegate void SimpleDelegate();3.static void F() {4.System.Console.WriteLine("Test.F");5.}6.static void Main() {7.SimpleDelegate d = new SimpleDelegate(F);8.d();9.}10.}What will be the output of above code when compiled/run?

The code will compile successfully.

1.class Test{2.public static void Main(){3.int i=0;4.char c='s';5.object[] objArray=new object[3];7.objArray[0]=i;8.objArray[0]=c;//new char();9.}10.}The above code is compiled and run. The possible error is:

The try block throws an exception hence the control goes to catch block but line number 11 and 12 does not produce the same output.

1.using System;2.class Test{3.public static void Main(){4.try{5.int p=10;6.Console.WriteLine("enter a number");7.int r=Int32.Parse(Console.ReadLine());8.p/=r;9.}10.catch(Exception e){11.Console.WriteLine(e);12.Console.WriteLine(Console.Error);13.}14.}15.}Above program is compiled and run.The user enters 0 when asked for the number.Does the code at line 11 and 12 displays the same output?

Longest answer

A command builder is only able to autogenerate SQL commands for use by a data adapter, if

method

A constructor is a special type of a _______ in a class.

Complex control

A custom control should you use to verify an authorized aplication user called as

Complex Control

A custom control should you use to verify an authorized aplication user called as _____

Callable entity

A delegate instance encapsulates one or more methods, each of which is referred to as a _________

Intermediate Language

A program in .NET is first compiled by the language specific compiler into

Server

A remote object is an object that runs on...

It issues an I/O request

A thread object will change to "Blocked" state, when ...

Website

A web application running on multiple servers is called as

.NET Data Provider | DataSets

ADO.NET has two core components, are

false

ADO.NET provides a single set of types that communicate

False

An assembly cannot be used in more than one application at a time.

IL Code and Resources

An assembly consists of Assembly Metadata. Type Metadata. _ and

False

An instance of a delegate type encapsulates one or more callable entities.

Abstract

Any class that contain one or more abstract methods must be declared as ____

Client side code is executed on the browser. Server side code is executed at the server side on IIS in ASP.NET framework.

Choose 2- correct statements about server-side and Client-side codes?

Namespaces

Classes in the Base Class Library are categorized into ______ based on their functionality

event subscribers

Clients can attach executable code for events by supplying ____________

String

Console.ReadLine() returns the input as a ________

0

Console.WriteLine(dtColumns.Count);

1

Console.WriteLine(o1.ToString());

No

Do we have to set value for a variable before using?

Yes, but only for inheritance from many interfaces.

Does C# support multi inherritance?(Choose the most correct answer)

Anchor

In Windows Form application,. which property is used to get or set the edges of the control is anchored to the edges of its container?

DialogResult

In Winfroms, ___ property is used to get or set value that is returned to the parent from when the button is clicked

Prelnit

In below events of page, which one is raised first

False

Indexers can have user-defined names

Hints + Properties

IntelliSence pops up a list of ___ that can be called on an onject

Properties

IntelliSence pops up a list of _____that can be called on an object

Class View

Presents a logical view of our work using an Explorer-like view of the classes, methods and properties

False

Private assemblies have no versioning policy.

Both Output Caching and DataCaching

Select the caching type supported by ASP.Net

Repeater

Select the control which does not have any visible interface

Commerce Server 2000 va Exchange 2000 Server

Select the core .NET Enterprise Servers

Transfers all the form data to test.aspx with HTTP headers

Select the output of the statement < form method=post action="test.aspx" >

Calendar

Select the service, which allows users to maintain their schedules thus facilitating timely and manageable interactions with other users.

RegularExpressionValidator

Select the validation control used for "PatternMatching"

System.Web.SessionState

Session Object classes are defined in which of the following namespace?

interact with the system environment

System namespace is used in the C# programs to:

2008

System.Console.WriteLine ("The value of x & y is : {0}". (x & y));

Command

The ... object allows us to rertrieve & manipulate data in the database.

TCP /IP va HTTP

The .NET platform is built on Internet Protocols such as _______ and _______

Reliability va Security va Manageability

The .NET platform is built on the following features of the Windows 2000 server family.(Select all that apply)

< asp:label >

The Asp.net server control, which provides an alternative way of displaying text on web page, is

Columns. Constraints

The DataTable structure is defined by its _ and _.

Common Language Runtime

The Following are the minimum requirement to run Asp.net pages?

System.Drawing

The Pen class belongs to the ____namespace and cannot be inherited

System.Array.Sort(Arraytosort)

The Syntax of a predefined Sort method is:

Console

The WriteLine method is a part of the ______ class

ToolTip

The ___ control is used to display text when the mouse points to a particular control

Load

The ____ event of the Form control is used to perform tasks such as allocatin

Load

The ____ event of the Form control is used to perform tasks such as allocating resources used by the form

LinkArea

The ____ property of the LinkLabel control is used to specity the text, which has to be displayed as a link.

An Assembly

The _____ package forms the basic unit of versioning.

Interface

The ______ declares a reference type that has abstract member only.

set

The ______ method is used to assign some value to a data member in a class.

System.Array

The _______ namespace provides the classes and methods for manipulating arrays.

System.Thread

The _______________ namespace contains classes useful for synchronization.

System

The ________namespace contains all code required to interact with the including the console output.

Object

The _______class is the ultimate base class for all data types.

Page_Init

The first event to be triggered in an aspx page is ...

in the <drive>:\WINNT\Assembly folder.

The global assemblies are saved in the _________

Reflection

The information about a class can be found out using ________

System.UI.Naming.Container

The interface used by ASP.Net to create Unique Id's?

@

The prefix ______ enables the use of keywords as identifiers, which is useful when interfacing with other programming languages.

sn -k key1.snkcsc /out:pri.dll /target:library file2.cs /a .keyfile:key.snkgautil -I pri.dll

The programmer has an assembly named pri.dll which other programmer also wants used the same assembly. Which of the following are the correct statements when executed will satisfy the above needs.

DataType[] arrayname;

The syntax for declaring array is:

csc /out:<assembly name>/target:library <filename1 filename2..>

The syntax to create an assembly file is:

Delegate

The type of event declaration must be of ... type.

Event

The type of event declaration must be of _________ type.

ListBox

The types of list box supported in Winforms are

Multi-language

The unique feature of .NET is the ___________support that it provides

False

The value of the HelpButton property is ignored if the maximize of minimize boxes are shown

False

The value of the HelpButton property is ignored if the maximize of minimize boxes are shown.

Report View

The view types supported in Winforms are

QueryPageSettings

The____ event of the PrintDocument class is triggered immediately before each PrintPage event ocurs

DataSource

The____property of a DataGrid control, allow filling various kinds of data in a DataGrid including data from a DataSet, DataViewManager, Arrays, Lists etc

Enumerations are a handy programming construct that allows to group name/value pairs.

What are enumerations?

Single Cast delegate va Multi Cast delegate.

Two types of delegates are:

Block and Unblock

We can use ... and ... methods to ensure that application-level variables are not updated by more than one user simultaneously

Legal at compile and runtime

We have the following organization of classes.class Parent { } class DerivedOne :Parent { } class DerivedTwo :Parent { }Which of the following statements is correct for the followingexpression.Parent p = new Parent();DerivedOne d1 = new DerivedOne();DerivedTwo d2 = new DerivedTwo();p = d1;

(a) incorrect, (b) correct

We have two sentences: ADO.NET provides a single set of types that communicate with multiple database management systems (DBMSs). ADO.NET supports multiple data providers, each of which is optimized to interact with a specific DBMS

XML and SOAP

Web service technology is based on what?

HTML controls

What are NOT Web Server controls?

A discovery service, a description service and a transport protocol

What are building blocks of an XML Web service

VBScript and JavaScript

What are client-side script languages

The code will compile successfully and outputs will be:1 2

What output does the code below generate when compiled/run?1.class Employee{2.public int EmployeeId;3.public static Employee getEmpId(int EmpId){4.Employee emp=new Employee();5.emp.EmployeeId=EmpId;6.return(emp);7.}8.}9.class Test{10.public static void Main(){11.Employee[] emps=new Employee[2];12.emps[0]=Employee.getEmpId(1);13.emps[1]=Employee.getEmpId(2);14.foreach(Employee e in emps)15.System.Console.WriteLine(e.EmployeeId);16.}}

Both of I and II statements are correct

What statement in the followings is correct I. The instance properties and methods are those, which are common to all the instances of the class. II. The shared properties and methods are those, which are specific to a particular instance.

break

What statement is used to completely abort the execution of a loop?

The code compiles and "5, Sub" is printed on the standard output.

What will be printed to standard output?class Super{public int index = 5;public virtual void printVal() {System.Console.WriteLine( "Super" );}}class Sub : Super{int index = 2;public override void printVal() {System.Console.WriteLine( "Sub" );}}public class Runner {public static void Main( ) {Super sup = new Sub();System.Console.WriteLine( sup.index + "," );sup.printVal();}}

The code will compile successfully and output will be ProgrammingInc#

What will be the output of the code below when compiled/run?1.class Test {2.public static void Print(object[] arr){3.foreach(object p in arr)4.System.Console.WriteLine(p);5.}6.public static void Main(){7.string s="Programming in c#";8.char[] separator={' '};9.string[] words=s.Split(separator);10.Print(words);11.}}

Two

What would be the output of the following code fragment?int x=0,y=4,z=5;if(x<2)if(y<4){Console.WriteLine("One");}else {Console.WriteLine("Two");}else if(z>5){Console.WriteLine("Three");}else {Console.WriteLine("Four");}

Clears all Headers from the buffer stream

Whats is the significance of Response.ClearHeaders( ) ?

Maps the specified virtual path to a physical path

Whats the significance of Request.MapPath( ) ?

It s invoked when the stack does not have sufficient memory to allocate a requested object

Whe n is the garbage collector invoked?

DataReader Connection Command

When a Data Form is created using the Data Form Wizard

OleDbDataReader va OleDbConnection va OleDbCommand

When a Data Form is created using the Data Form Wizard, which of the following classes are used by default?(Choose all correct answers)

Unqualified name

When a class is used inside its namespace, the _______ of that class is used.

All the options mentioned

Within the namespace we can declare following:

many constructor | only one destructor

a class can have

is create with the new operator

a delegate object

false

a given application domain can have only thread executing with it at any given time

compile error

base.display()

Dir ["S"]="SMITH"; Dir ["M"]="MARTIN";

class Question{public Hashtable Directory = new Hashtable();public string this[string Person] {get {return (string) Directory[Person];}set {Directory[Person] = value;}}}class Test {static void Main() {Question Dir = new Question();// Add code here. . . . . . . .}}Two persons named SMITH and MARTIN are to be added in the directory created above. To achieve this which of the following are the valid statements that can be added in the space specified in the code above?

The code will compile successfully and output the following text:In Try In Finally

class Question{public static void Main(){Function1();}static void Function1(){try{System.Console.WriteLine("In Try");return;}finally{System.Console.WriteLine("In Finally");}}}What will be the output of above code when compile/run?

False, True

class Room{int number=0;public bool isEmpty(){return (number>0);}}class StaffRoom: Room{int number=10;public new bool isEmpty(){return (number>0);}public static void Main() {Room R1=new StaffRoom();System.Console.WriteLine(R1.isEmpty());StaffRoom R2=new StaffRoom();System.Console.WriteLine(R2.isEmpty());}}The output of above code will be:

Init A A.F Init B B.F

class Test{ static void Main() { A.F(); B.F(); } }class A { static A() //static constructor{ Console.WriteLine("Init A"); }public static void F() { Console.WriteLine("A.F"); } }class B { static B() { Console.WriteLine("Init B"); }public static void F() { Console.WriteLine("B.F"); } }

0

class Test{static void Main() {int[] Array1= {3,2,1};int i=Array.IndexOf(Array1,3);Console.WriteLine(i);}}What will be the output of above code

Hello

given the following code segment, what is the output? string s ="Hello"; string r; r = s; r+="World!"; System.Console.WriteLine(s);

this code has error at line : h.name = "nguyen van a"

h.name = "nguyen van a";

compile error

int x = 2009;

GG() va FF()

interface IMethods { void F(); void G(); }abstract class C: IMethods { void IMethods.F() { FF(); }void IMethods.G() { GG(); }protected abstract void FF();protected abstract void GG(); }Consider the above code.The non-abstract that derive from C will have to implement:

compile error at line: void display()

interface animal

one, two, three must be interfaces.

interface intA: one, two,three{ }Which of the following statements are true for the above code?

commandArgument property | controlToValidate property

name two properties common in every validation control?

runtime error

object o1 = n1;

multiple interface

public class A:B,C,D{ }The above code represents ______

runtime error

sqlconnection cn = new sqlconnection();

compile error

system.data.sqlclient.sqlcommand cmd = cn.createcommand()

runtime error

system.data.sqlclient.sqlconnection cn = new system.data.sqlclient.sqlconnection()

1

the number of forms that can be add to an ASPX page is

Group Name

the property of the Radio Button control restricts the users to select only one option from a give set of options

all of above

to add a custom control to web form, we have to register with

The code will generate a compilation error, as parent class does not have a display method with one argument.

using System;public class Parent {public virtual void Display(){Console.WriteLine("100"); }}public class Child1:Parent {public override void Display(){Console.WriteLine("1000");}public void Display(int i){Console.WriteLine("{0}",i);}}public static void Main() {Parent p =new Child1();p.Display();p.Display(90);}}What will be the output of above code when compile/run?

The output of the code will be:1000 1000

using System;public class Parent {public virtual void Display(){Console.WriteLine("100"); }}public class Child1:Parent {public override void Display(){Console.WriteLine("1000");}}public class Child2:Parent {public override void Display(){Console.WriteLine("1000");}public static void Main() {Child1 c1=new Child1();Child2 c2=new Child2();Parent p=c2;c1.Display();p.Display();}}will be the output of above code when compile/run?

is valid

validity a page can be checked using the ... propertied

sentence 1 is correct, sentence 2 is not correct

vbscript and javascript are client-side script codes

lock and unlock

we can use...and...methods to ensure that application level variables are not update more than one user simultaneously

preRender(), Load(), Init(), unload()

what 4-methods are fired during the page load?

uniqueConstraint | foreignKeyConstraint

what are kinds of constraint in ADO.NET?

Extension methods | Automatic properties

what are new language enhancements in Visual Studio 2008?

after the web form loads

when the user control's code is executed

executeNonQuery

when update an existing record in one table of database, should we use which method of command objects?

it is available to any sub-class derived from base class

where is a protected class-level variable available?

Control

which class is the base class for all the controls that can be used in Windows Forms?

listbox

which control is a kind of value setting controls?

lable

which control is not used to receice information?

helpProvider

which control is used to link an html file the WinForms application?

textbox

which control is usually used to input text

session_start()

which event handler is fired when a new user logs on to your application?

selectedIndexChanged

which event is raised when user choose in item in combobox control?

unload

which event of the page type is fired lastly when loading the page?

Is postback is read only property of system.web.UI.page class

which is the following sentence is true

prerender()

which method is fired lastly during the page load?

SqlCommandBuilder

which object is used to automatically generate commands

command

which object provides access to the provider's data reader object?

a collection of datarow object

which object represents the actual data of a datatable?

cookies

which of following field is not valid state management tool

execute

which of following is not member of response object

aspx

which of the following extension dose a web service file will have?

execute

which of the following is not a member of response object?

dock

which property of control type is used to get a widget should be attached to which side (or side) of a form

top

which property of control type is used to set a widget should be attached to which side (or sides) of a form?

cancelbutton

which property of the form type sets the button on the form that is clicked then user press the esc key?

LCID

which property of the session object is used to set the local identifier

destructor of student class | destructor of human class

~human()


Ensembles d'études connexes

OSCM 306 Midterm 1 Multiple Choice and True/False (Chapters 1, 2, 4, 6).

View Set

Labor Relations: Striking a Balance chapter 1

View Set

Psych Final Pt. 3, Psych Final, Psych Final Pt. 1, Chapter 13, Psych Final Pt. 1, Chapter 13

View Set

Chapter 3: Project Management Process Groups (ITPM)

View Set