You are on page 1of 34

.

NET Framework
From Wikipedia, the free encyclopedia
Jump to: navigation, search
This article is about the Microsoft technology. For the Top-level domain, see .net.
For other uses, see .NET
.NET Framework

Developer(s) Microsoft
Initial release February 13, 2002
4.0.30319.1 (4.0) / 12 April 2010; 3
Stable release
months ago
Windows 98 or later, Windows NT 4.0 or
Operating system
later
Type Software framework
MS-EULA, BCL under Microsoft
License
Reference Source License[1]
Website http://msdn.microsoft.com/netframework/

The Microsoft .NET Framework is a software framework that can be installed on


computers running Microsoft Windows operating systems. It includes a large library of
coded solutions to common programming problems and a virtual machine that manages
the execution of programs written specifically for the framework. The .NET Framework
supports multiple programming languages in a manner that allows language
interoperability, whereby each language can utilize code written in other languages; in
particular, the .NET library is available to all the programming languages that .NET
encompasses. The .NET Framework is a Microsoft offering and is intended to be used by
most new applications created for the Windows platform. In order to be able to develop
and not just run applications for the Microsoft .NET Framework 4.0, it is required to have
Microsoft's SDK for Windows 7 and .NET Framework 4 (or newer) or Visual Studio
2010 installed on your computer.

The framework's Base Class Library provides a large range of features including user
interface, data access, database connectivity, cryptography, web application development,
numeric algorithms, and network communications. The class library is used by
programmers, who combine it with their own code to produce applications.

Programs written for the .NET Framework execute in a software environment that
manages the program's runtime requirements. Also part of the .NET Framework, this
runtime environment is known as the Common Language Runtime (CLR). The CLR
provides the appearance of an application virtual machine so that programmers need not
consider the capabilities of the specific CPU that will execute the program. The CLR also
provides other important services such as security, memory management, and exception
handling. The class library and the CLR together constitute the .NET Framework.

Version 3.0 of the .NET Framework is included with Windows Server 2008 and
Windows Vista. Version 3.5 is included with Windows 7, and can also be installed on
Windows XP and the Windows Server 2003 family of operating systems.[2] On April 12,
2010, .NET Framework 4 was released alongside Visual Studio 2010.

The .NET Framework family also includes two versions for mobile or embedded device
use. A reduced version of the framework, the .NET Compact Framework, is available on
Windows CE platforms, including Windows Mobile devices such as smartphones.
Additionally, the .NET Micro Framework is targeted at severely resource-constrained
devices.

Contents
[hide]
 1 Principal design features
 2 Architecture
o 2.1 Common Language Infrastructure (CLI)
o 2.2 Assemblies
o 2.3 Metadata
o 2.4 Security
o 2.5 Class library
o 2.6 Memory management
 3 Standardization and licensing
 4 Versions
o 4.1 .NET Framework 1.0
o 4.2 .NET Framework 1.1
 4.2.1 Changes in 1.1 on comparison with 1.0
o 4.3 .NET Framework 2.0
 4.3.1 Changes in 2.0 in comparison with 1.1
o 4.4 .NET Framework 3.0
o 4.5 .NET Framework 3.5
 4.5.1 Changes since version 3.0
 4.5.2 Service Pack 1
 4.5.3 .NET Framework 3.5 SP1 Client Profile
o 4.6 .NET Framework 4
 5 .NET vs. Java and Java EE
 6 Criticism
 7 Alternative implementations
 8 See also
o 8.1 Components and libraries
 9 References

 10 External links

[edit] Principal design features


Interoperability 
Because interaction between new and older applications is commonly required,
the .NET Framework provides means to access functionality that is implemented
in programs that execute outside the .NET environment. Access to COM
components is provided in the System.Runtime.InteropServices and
System.EnterpriseServices namespaces of the framework; access to other
functionality is provided using the P/Invoke feature.
Common Runtime Engine 
The Common Language Runtime (CLR) is the virtual machine component of
the .NET Framework. All .NET programs execute under the supervision of the
CLR, guaranteeing certain properties and behaviors in the areas of memory
management, security, and exception handling.
Language Independence 
The .NET Framework introduces a Common Type System, or CTS. The CTS
specification defines all possible datatypes and programming constructs supported
by the CLR and how they may or may not interact with each other conforming to
the Common Language Infrastructure (CLI) specification. Because of this feature,
the .NET Framework supports the exchange of types and object instances between
libraries and applications written using any conforming .NET language.
Base Class Library 
The Base Class Library (BCL), part of the Framework Class Library (FCL), is a
library of functionality available to all languages using the .NET Framework. The
BCL provides classes which encapsulate a number of common functions,
including file reading and writing, graphic rendering, database interaction, XML
document manipulation and so on.
Simplified Deployment 
The .NET Framework includes design features and tools that help manage the
installation of computer software to ensure that it does not interfere with
previously installed software, and that it conforms to security requirements.
Security 
The design is meant to address some of the vulnerabilities, such as buffer
overflows, that have been exploited by malicious software. Additionally, .NET
provides a common security model for all applications.
Portability 
The design of the .NET Framework allows it to theoretically be platform agnostic,
and thus cross-platform compatible. That is, a program written to use the
framework should run without change on any type of system for which the
framework is implemented. While Microsoft has never implemented the full
framework on any system except Microsoft Windows, the framework is
engineered to be platform agnostic,[3] and cross-platform implementations are
available for other operating systems (see Silverlight and the Alternative
implementations section below). Microsoft submitted the specifications for the
Common Language Infrastructure (which includes the core class libraries,
Common Type System, and the Common Intermediate Language),[4][5][6] the C#
language,[7] and the C++/CLI language[8] to both ECMA and the ISO, making
them available as open standards. This makes it possible for third parties to create
compatible implementations of the framework and its languages on other
platforms.

[edit] Architecture

Visual overview of the Common Language Infrastructure (CLI)

[edit] Common Language Infrastructure (CLI)

Main article: Common Language Infrastructure

The purpose of the Common Language Infrastructure, or CLI, is to provide a language-


neutral platform for application development and execution, including functions for
exception handling, garbage collection, security, and interoperability. By implementing
the core aspects of the .NET Framework within the scope of the CLR, this functionality
will not be tied to a single language but will be available across the many languages
supported by the framework. Microsoft's implementation of the CLI is called the
Common Language Runtime, or CLR.
[edit] Assemblies

Main article: .NET assembly

The CIL code is housed in .NET assemblies. As mandated by specification, assemblies


are stored in the Portable Executable (PE) format, common on the Windows platform for
all DLL and EXE files. The assembly consists of one or more files, one of which must
contain the manifest, which has the metadata for the assembly. The complete name of an
assembly (not to be confused with the filename on disk) contains its simple text name,
version number, culture, and public key token. The public key token is a unique hash
generated when the assembly is compiled, thus two assemblies with the same public key
token are guaranteed to be identical from the point of view of the framework.[dubious – discuss]
A private key can also be specified known only to the creator of the assembly and can be
used for strong naming and to guarantee that the assembly is from the same author when
a new version of the assembly is compiled (required to add an assembly to the Global
Assembly Cache).

[edit] Metadata

Main article: .NET metadata

All CIL is self-describing through .NET metadata. The CLR checks the metadata to
ensure that the correct method is called. Metadata is usually generated by language
compilers but developers can create their own metadata through custom attributes.
Metadata contains information about the assembly, and is also used to implement the
reflective programming capabilities of .NET Framework.

[edit] Security

.NET has its own security mechanism with two general features: Code Access Security
(CAS), and validation and verification. Code Access Security is based on evidence that is
associated with a specific assembly. Typically the evidence is the source of the assembly
(whether it is installed on the local machine or has been downloaded from the intranet or
Internet). Code Access Security uses evidence to determine the permissions granted to
the code. Other code can demand that calling code is granted a specified permission. The
demand causes the CLR to perform a call stack walk: every assembly of each method in
the call stack is checked for the required permission; if any assembly is not granted the
permission a security exception is thrown.

When an assembly is loaded the CLR performs various tests. Two such tests are
validation and verification. During validation the CLR checks that the assembly contains
valid metadata and CIL, and whether the internal tables are correct. Verification is not so
exact. The verification mechanism checks to see if the code does anything that is 'unsafe'.
The algorithm used is quite conservative; hence occasionally code that is 'safe' does not
pass. Unsafe code will only be executed if the assembly has the 'skip verification'
permission, which generally means code that is installed on the local machine.
.NET Framework uses Application Domains as a mechanism for isolating code running
in a process. Application Domains can be created and code loaded into or unloaded from
them independent of other Application Domains. This helps increase the fault tolerance
of the application, as faults or crashes in one Application Domain do not affect the rest of
the application. Application Domains can also be configured independently with different
security privileges. This can help increase the security of the application by isolating
potentially unsafe code. The developer, however, has to split the application into
subdomains; it is not done by the CLR.

[edit] Class library

Namespaces in the BCL[9]


System
System. CodeDom
System. Collections
System. Diagnostics
System. Globalization
System. IO
System. Resources
System. Text
System. Text.RegularExpressions
See also: Base Class Library and Framework Class Library

The .NET Framework includes a set of standard class libraries. The class library is
organized in a hierarchy of namespaces. Most of the built in APIs are part of either
System.* or Microsoft.* namespaces. These class libraries implement a large number
of common functions, such as file reading and writing, graphic rendering, database
interaction, and XML document manipulation, among others. The .NET class libraries
are available to all CLI compliant languages. The .NET Framework class library is
divided into two parts: the Base Class Library and the Framework Class Library.

The Base Class Library (BCL) includes a small subset of the entire class library and is the
core set of classes that serve as the basic API of the Common Language Runtime.[9] The
classes in mscorlib.dll and some of the classes in System.dll and System.core.dll
are considered to be a part of the BCL. The BCL classes are available in both .NET
Framework as well as its alternative implementations including .NET Compact
Framework, Microsoft Silverlight and Mono.

The Framework Class Library (FCL) is a superset of the BCL classes and refers to the
entire class library that ships with .NET Framework. It includes an expanded set of
libraries, including Windows Forms, ADO.NET, ASP.NET, Language Integrated Query,
Windows Presentation Foundation, Windows Communication Foundation among others.
The FCL is much larger in scope than standard libraries for languages like C++, and
comparable in scope to the standard libraries of Java.
[edit] Memory management

The .NET Framework CLR frees the developer from the burden of managing memory
(allocating and freeing up when done); instead it does the memory management itself. To
this end, the memory allocated to instantiations of .NET types (objects) is done
contiguously[10] from the managed heap, a pool of memory managed by the CLR. As long
as there exists a reference to an object, which might be either a direct reference to an
object or via a graph of objects, the object is considered to be in use by the CLR. When
there is no reference to an object, and it cannot be reached or used, it becomes garbage.
However, it still holds on to the memory allocated to it. .NET Framework includes a
garbage collector which runs periodically, on a separate thread from the application's
thread, that enumerates all the unusable objects and reclaims the memory allocated to
them.

The .NET Garbage Collector (GC) is a non-deterministic, compacting, mark-and-sweep


garbage collector. The GC runs only when a certain amount of memory has been used or
there is enough pressure for memory on the system. Since it is not guaranteed when the
conditions to reclaim memory are reached, the GC runs are non-deterministic. Each .NET
application has a set of roots, which are pointers to objects on the managed heap
(managed objects). These include references to static objects and objects defined as local
variables or method parameters currently in scope, as well as objects referred to by CPU
registers.[10] When the GC runs, it pauses the application, and for each object referred to
in the root, it recursively enumerates all the objects reachable from the root objects and
marks them as reachable. It uses .NET metadata and reflection to discover the objects
encapsulated by an object, and then recursively walk them. It then enumerates all the
objects on the heap (which were initially allocated contiguously) using reflection. All
objects not marked as reachable are garbage.[10] This is the mark phase.[11] Since the
memory held by garbage is not of any consequence, it is considered free space. However,
this leaves chunks of free space between objects which were initially contiguous. The
objects are then compacted together to make used memory contiguous again.[10][11] Any
reference to an object invalidated by moving the object is updated to reflect the new
location by the GC.[11] The application is resumed after the garbage collection is over.

The GC used by .NET Framework is actually generational.[12] Objects are assigned a


generation; newly created objects belong to Generation 0. The objects that survive a
garbage collection are tagged as Generation 1, and the Generation 1 objects that survive
another collection are Generation 2 objects. The .NET Framework uses up to Generation
2 objects.[12] Higher generation objects are garbage collected less frequently than lower
generation objects. This helps increase the efficiency of garbage collection, as older
objects tend to have a larger lifetime than newer objects.[12] Thus, by removing older (and
thus more likely to survive a collection) objects from the scope of a collection run, fewer
objects need to be checked and compacted.[12]

[edit] Standardization and licensing


In August 2000, Microsoft, Hewlett-Packard, and Intel worked to standardize CLI and
the C# programming language. By December 2001, both were ratified ECMA standards
(ECMA 335 and ECMA 334). ISO followed in April 2003 - the current version of the
ISO standards are ISO/IEC 23271:2006 and ISO/IEC 23270:2006.[13][14]

While Microsoft and their partners hold patents[citation needed] for the CLI and C#, ECMA and
ISO require that all patents essential to implementation be made available under
"reasonable and non-discriminatory terms". In addition to meeting these terms, the
companies have agreed to make the patents available royalty-free.[citation needed]

However, this does not apply for the part of the .NET Framework which is not covered
by the ECMA/ISO standard, which includes Windows Forms, ADO.NET, and ASP.NET.
Patents that Microsoft holds[citation needed] in these areas may deter non-Microsoft
implementations of the full framework.[15]

On 3 October 2007, Microsoft announced that much of the source code for the .NET
Framework Base Class Library (including ASP.NET, ADO.NET, and Windows
Presentation Foundation) was to have been made available with the final release of
Visual Studio 2008 towards the end of 2007 under the shared source Microsoft Reference
License.[1] The source code for other libraries including Windows Communication
Foundation (WCF), Windows Workflow Foundation (WF), and Language Integrated
Query (LINQ) were to be added in future releases. Being released under the non Open-
source Microsoft Reference License means this source code is made available for
debugging purpose only, primarily to support integrated debugging of the BCL in Visual
Studio.

[edit] Versions
Microsoft started development on the .NET Framework in the late 1990s originally under
the name of Next Generation Windows Services (NGWS). By late 2000 the first beta
versions of .NET 1.0 were released.[16]
The .NET Framework stack.
Version Release
Version Visual Studio Default in Windows
Number Date
1.0 1.0.3705.0 2002-02-13 Visual Studio .NET
Visual Studio .NET
1.1 1.1.4322.573 2003-04-24 Windows Server 2003
2003
2.0 2.0.50727.42 2005-11-07 Visual Studio 2005
Windows Vista, Windows
3.0 3.0.4506.30 2006-11-06
Server 2008
Windows 7, Windows Server
3.5 3.5.21022.8 2007-11-19 Visual Studio 2008
2008 R2
4.0 4.0.30319.1 2010-04-12 Visual Studio 2010

A more complete listing of the releases of the .NET Framework may be found on the
.NET Framework version list.

[edit] .NET Framework 1.0

The old .NET Framework logo


This is the first release of the .NET Framework, released on 13 February 2002 and
available for Windows 98, Me, NT 4.0, 2000, and XP. Mainstream support by Microsoft
for this version ended 10 July 2007, and extended support ended 14 July 2009.[17]

[edit] .NET Framework 1.1

This is the first major .NET Framework upgrade. It is available on its own as a
redistributable package or in a software development kit, and was published on 3 April
2003. It is also part of the second release of Microsoft Visual Studio .NET (released as
Visual Studio .NET 2003). This is the first version of the .NET Framework to be included
as part of the Windows operating system, shipping with Windows Server 2003.
Mainstream support for .NET Framework 1.1 ended on 14 October 2008, and extended
support ends on 8 October 2013. Since .NET 1.1 is a component of Windows Server
2003, extended support for .NET 1.1 on Server 2003 will run out with that of the OS -
currently 14 July 2015.

[edit] Changes in 1.1 on comparison with 1.0

 Built-in support for mobile ASP.NET controls. Previously available as an add-on


for .NET Framework, now part of the framework.
 Security changes - enable Windows Forms assemblies to execute in a semi-trusted
manner from the Internet, and enable Code Access Security in ASP.NET
applications.
 Built-in support for ODBC and Oracle databases. Previously available as an add-
on for .NET Framework 1.0, now part of the framework.
 .NET Compact Framework - a version of the .NET Framework for small devices.
 Internet Protocol version 6 (IPv6) support.
 Numerous API changes.

[edit] .NET Framework 2.0

Released with Visual Studio 2005, Microsoft SQL Server 2005, and BizTalk 2006.

 The 2.0 Redistributable Package can be downloaded for free from Microsoft, and
was published on 22 January 2006.
 The 2.0 Software Development Kit (SDK) can be downloaded for free from
Microsoft.
 It is included as part of Visual Studio 2005 and Microsoft SQL Server 2005.
 Version 2.0 without any Service Pack is the last version with support for
Windows 98 and Windows Me. Version 2.0 with Service Pack 2 is the last
version with official support for Windows 2000 although there have been some
unofficial workarounds published online to use a subset of the functionality from
Version 3.5 in Windows 2000.[18] Version 2.0 with Service Pack 2 requires
Windows 2000 with SP4 plus KB835732 or KB891861 update, Windows XP
with SP2 or later and Windows Installer 3.1 (KB893803-v2)
 It shipped with Windows Server 2003 R2 (not installed by default).
[edit] Changes in 2.0 in comparison with 1.1

 Generics
 Language support for generics built directly into the .NET CLR.
 Full 64-bit support for both the x64 and the IA64 hardware platforms.
 Numerous API changes.
 SQL Server integration - .NET 2.0, VS 2005, and SQL Server 2005 are all tied
together. This means that instead of using T-SQL, one can build stored procedures
and triggers in any of the .NET-compatible languages.
 A new hosting API for native applications wishing to host an instance of the .NET
runtime. The new API gives a fine grain control on the behavior of the runtime
with regards to multithreading, memory allocation, assembly loading and more
(detailed reference). It was initially developed to efficiently host the runtime in
Microsoft SQL Server, which implements its own scheduler and memory
manager.
 Many additional and improved ASP.NET web controls.
 New data controls with declarative data binding.
 New personalization features for ASP.NET, such as support for themes, skins,
master pages and webparts.
 .NET Micro Framework - a version of the .NET Framework related to the Smart
Personal Objects Technology initiative.
 Membership provider
 Partial classes
 Nullable types
 Anonymous methods
 Iterators
 Data tables

[edit] .NET Framework 3.0

.NET Framework 3.0, formerly called WinFX,[19] was released on 21 November 2006. It
includes a new set of managed code APIs that are an integral part of Windows Vista and
Windows Server 2008 operating systems. It is also available for Windows XP SP2 and
Windows Server 2003 as a download. There are no major architectural changes included
with this release; .NET Framework 3.0 uses the Common Language Runtime of .NET
Framework 2.0.[20] Unlike the previous major .NET releases there was no .NET Compact
Framework release made as a counterpart of this version. Version 3.0 of the .NET
Framework shipped with Windows Vista. It also shipped with Windows Server 2008 as
an optional component (disabled by default).

.NET Framework 3.0 consists of four major new components:

 Windows Presentation Foundation (WPF), formerly code-named Avalon; a new


user interface subsystem and API based on XML and vector graphics, which uses
3D computer graphics hardware and Direct3D technologies. See WPF SDK for
developer articles and documentation on WPF.
 Windows Communication Foundation (WCF), formerly code-named Indigo; a
service-oriented messaging system which allows programs to interoperate locally
or remotely similar to web services.
 Windows Workflow Foundation (WF) allows for building of task automation and
integrated transactions using workflows.
 Windows CardSpace, formerly code-named InfoCard; a software component
which securely stores a person's digital identities and provides a unified interface
for choosing the identity for a particular transaction, such as logging in to a
website.

[edit] .NET Framework 3.5

Version 3.5 of the .NET Framework was released on 19 November 2007, but it is not
included with Windows Server 2008. As with .NET Framework 3.0, version 3.5 uses the
CLR of version 2.0. In addition, it installs .NET Framework 2.0 SP1, (installs .NET
Framework 2.0 SP2 with 3.5 SP1) and .NET Framework 3.0 SP1 (installs .NET
Framework 3.0 SP2 with 3.5 SP1), which adds some methods and properties to the BCL
classes in version 2.0 which are required for version 3.5 features such as Language
Integrated Query (LINQ). These changes do not affect applications written for version
2.0, however.[21]

As with previous versions, a new .NET Compact Framework 3.5 was released in tandem
with this update in order to provide support for additional features on Windows Mobile
and Windows Embedded CE devices.

The source code of the Base Class Library in this version has been partially released (for
debugging reference only) under the Microsoft Reference Source License.[1]

[edit] Changes since version 3.0

 New language features in C# 3.0 and VB.NET 9.0 compiler


 Adds support for expression trees and lambda methods
 Extension methods
 Expression trees to represent high-level source code at runtime.[22]
 Anonymous types with static type inference
 Language Integrated Query (LINQ) along with its various providers
o LINQ to Objects
o LINQ to XML
o LINQ to SQL
 Paging support for ADO.NET
 ADO.NET synchronization API to synchronize local caches and server side
datastores
 Asynchronous network I/O API.[22]
 Peer-to-peer networking stack, including a managed PNRP resolver[23]
 Managed wrappers for Windows Management Instrumentation and Active
Directory APIs[24]
 Enhanced WCF and WF runtimes, which let WCF work with POX and JSON
data, and also expose WF workflows as WCF services.[25] WCF services can be
made stateful using the WF persistence model.[22]
 Support for HTTP pipelining and syndication feeds.[25]
 ASP.NET AJAX is included.

[edit] Service Pack 1

The .NET Framework 3.5 Service Pack 1 was released on 11 August 2008. This release
adds new functionality and provides performance improvements under certain conditions,
[26]
especially with WPF where 20-45% improvements are expected. Two new data
service components have been added, the ADO.NET Entity Framework and ADO.NET
Data Services. Two new assemblies for web development, System.Web.Abstraction and
System.Web.Routing, have been added; these are used in the ASP.NET MVC
Framework and, reportedly, will be utilized in the future release of ASP.NET Forms
applications. Service Pack 1 is included with SQL Server 2008 and Visual Studio 2008
Service Pack 1. It also featured a new set of controls called "Visual Basic Power Packs"
which brought back Visual Basic controls such as "Line" and "Shape". Version 3.5 SP1
of the .NET Framework shipped with Windows 7. It also shipped with Windows Server
2008 R2 as an optional component (disabled by default).

[edit] .NET Framework 3.5 SP1 Client Profile

For the .NET Framework 3.5 SP1 there is also a new variant of the .NET Framework,
called the ".NET Framework Client Profile", which at 28 MB is significantly smaller than
the full framework and only installs components that are the most relevant to desktop
applications.[27] However, the Client Profile amounts to this size only if using the online
installer on Windows XP SP2 when no other .NET Frameworks are installed. When
using the off-line installer or any other OS, the download size is still 250 MB.[28]

[edit] .NET Framework 4

Microsoft announced the .NET Framework 4 on 29 September 2008. The Public Beta
was released on 20 May 2009.[29] Some focuses of this release are:

 Parallel Extensions to improve support for parallel computing, which target multi-
core or distributed systems.[30] To this end, they plan to include technologies like
PLINQ (Parallel LINQ),[31] a parallel implementation of the LINQ engine, and
Task Parallel Library, which exposes parallel constructs via method calls.[32]
 New Visual Basic .NET and C# language features, such as statement lambdas,
implicit line continuations, dynamic dispatch, named parameters, and optional
parameters.
 Full support for IronPython, IronRuby, and F#.[33]
 Support for a subset of the .NET Framework and ASP.NET with the "Server
Core" variant of Windows Server 2008 R2.[34]
 Support for Code Contracts.
 Inclusion of the Oslo modelling platform, along with the M programming
language.[35]
 Inclusion of new types to work with arbitrary-precision arithmetic
(System.Numerics.BigInteger) and complex numbers
(System.Numerics.Complex).

On 28 July 2009, a second release of the .NET Framework 4 beta was made available
with experimental software transactional memory support.[36] This functionality is not
available in the final version of the framework.

On 19 October 2009, Microsoft released Beta 2 of the .NET Framework 4.[37] At the same
time, Microsoft announced the expected launch date for .NET Framework 4 as the 22
March 2010.[37] This launch date was subsequently delayed to 12 April 2010.[38]

On 10 February 2010, a release candidate was published: Version:RC.[39]

On 12 April 2010, the final version of .NET Framework 4.0 was launched alongside the
final release of Visual Studio 2010.

In conjunction with .NET Framework 4, Microsoft will offer a set of enhancements,


codenamed Dublin, for Windows Server 2008 application server capabilities.[40][41] Dublin
will extend IIS to be a "standard host" for applications that use either WCF or WF.[41]

[edit] .NET vs. Java and Java EE


See also: Comparison of the Java and .NET platforms and Comparison of C# and Java

The CLI and .NET languages such as C# and VB have many similarities to Sun's JVM
and Java. Both are based on a virtual machine model that hides the details of the
computer hardware on which their programs run. Both use their own intermediate byte-
code, Microsoft calling theirs Common Intermediate Language (CIL; formerly MSIL)
and Sun calling theirs Java bytecode. On .NET the byte-code is always compiled before
execution, either Just In Time (JIT) or in advance of execution using the Native Image
Generator utility (NGEN). With Java the byte-code is either interpreted, compiled in
advance, or compiled JIT. Both provide extensive class libraries that address many
common programming requirements and address many security issues that are present in
other approaches. The namespaces provided in the .NET Framework closely resemble the
platform packages in the Java EE API Specification in style.

.NET in its complete form (i.e., Microsoft's implementation, described in the


Standardization and licensing section of this article) can only be installed on computers
running a Microsoft Windows operating system[42][43][44] whereas Java in its entirety can be
installed on computers running any one of a variety of operating systems such as Linux,
Solaris, Mac OS or Windows.[45] From its beginning .NET has supported multiple
programming languages and at its core remains platform agnostic and standardized so
that other vendors can implement it on other platforms (although Microsoft's
implementation only targets Windows, Windows CE, and Xbox platforms). The Java
Virtual Machine was also designed to be both language and operating system agnostic[46]
and was launched with the slogan "Write once, run anywhere." While Java has long
remained the most used language on the JVM by a wide margin, recent support for
dynamic languages has increased popularity of alternatives; in particular JRuby, Scala,
and Groovy.[47] (see JVM languages).

Sun's reference implementation of Java (including the class library, the compiler, the
virtual machine, and the various tools associated with the Java Platform) is open source
under the GNU GPL license with Classpath exception.[48] The source code for the .NET
Framework base class library is available for reference purposes only under the Microsoft
Reference License.[49][50]

The third-party Mono Project, sponsored by Novell, has been developing an open source
implementation of the ECMA standards that are part of .NET Framework, as well as most
of the other non-ECMA standardized libraries in Microsoft's .NET. The Mono
implementation is meant to run on Linux, Solaris, Mac OS X, BSD, HP-UX, and
Windows platforms. Mono includes the CLR, the class libraries, and compilers for C#
and VB.NET. The current version supports all the APIs in version 2.0 of Microsoft's
.NET. Full support exists for C# 3.0 LINQ to Objects and LINQ to XML.[51]

[edit] Criticism
Some concerns and criticism relating to .NET include:

 Applications running in a managed environment tend to require more system


resources than similar applications that access machine resources more directly.
 Unobfuscated managed CIL bytecode can often be easier to reverse-engineer than
native code.[52][53] One concern is over possible loss of trade secrets and the
bypassing of license control mechanisms. Since Visual Studio .NET (2002),
Microsoft has included a tool to obfuscate code (Dotfuscator Community
Edition).[54]
 Newer versions of the framework (3.5 and up) are not pre-installed in versions of
Windows below Windows 7. For this reason, applications must lead users without
the framework through a procedure to install it. Some developers have expressed
concerns about the large size of the .NET Framework runtime installers for end-
users. The size is around 54 MB for .NET 3.0, 197 MB for .NET 3.5, and 250 MB
for .NET 3.5 SP1 (while using web installer the typical download for Windows
XP is around 50 MB, for Windows Vista - 20 MB). The size issue is partially
solved with .NET 4 installer (x86 + x64) being 54 MB and not embedding full
runtime installation packages for previous versions. The .NET 3.5 SP1 full
installation package includes the full runtime installation packages for .NET 2.0
SP2 as well as .NET 3.0 SP2 for multiple operating systems (Windows XP/Server
2003 and Windows Vista/Server 2008) and for multiple CPU architectures (x86,
x86-64, and IA-64).
o The first service pack for version 3.5 mitigates this concern by offering a
lighter-weight client-only subset of the full .NET Framework. Two
significant limitations should be noted, though.[55] Firstly, the client-only
subset is only an option on an existing Windows XP SP2 system that
currently has no other version of the .NET Framework installed. In all
other scenarios, the client-only installer will install the full version of
the .NET Framework 3.5 SP1. Secondly, the client-only framework does
not have a 64-bit option. However, the 4 release of the .NET Framework
Client Profile will be available on all operating systems and all
architectures (excluding Itanium) supported by the full .NET Framework.
[56]

 The .NET Framework currently does not provide support for calling Streaming
SIMD Extensions (SSE) via managed code. However, Mono has provided support
for SIMD Extensions as of version 2.2 within the Mono.Simd namespace; Mono's
lead developer Miguel de Icaza has expressed hope that this SIMD support will be
adopted by the CLR ECMA standard.[57] Streaming SIMD Extensions have been
available in x86 CPUs since the introduction of the Pentium III. Some other
architectures such as ARM and MIPS also have SIMD extensions. In case the
CPU lacks support for those extensions, the instructions are simulated in software.
 While the standards that make up .NET are inherently cross platform, Microsoft's
full implementation of .NET is only supported on Windows. Microsoft does
provide limited .NET subsets for other platforms such as XNA for Windows,
XBOX 360 and Windows Phone 7; and Silverlight for Windows, Mac OS X, and
Windows Phone 7. Alternative implementations of the CLR, base class libraries,
and compilers also exist (sometimes from other vendors). While all of these
implementations are based on the same standards, they are still different
implementations with varying levels of completeness in comparison to the full
.NET version Microsoft ships for Windows and are on occasion[weasel  words]
incompatible.[citation needed]

[edit] Alternative implementations


The Microsoft .NET Framework is the predominant implementation of .NET
technologies. Other implementations for parts of the framework exist. Although the
runtime engine is described by an ECMA/ISO specification, other implementations of it
may be encumbered by patent issues; ISO standards may include the disclaimer,
"Attention is drawn to the possibility that some of the elements of this document may be
the subject of patent rights. ISO shall not be held responsible for identifying any or all
such patent rights."[58] It is more difficult to develop alternatives to the base class library
(BCL), which is not described by an open standard and may be subject to copyright
restrictions. Additionally, parts of the BCL have Windows-specific functionality and
behavior, so implementation on non-Windows platforms can be problematic.

Some alternative implementations of parts of the framework are listed here.


 Microsoft's Shared Source Common Language Infrastructure is a shared source
implementation of the CLR component of the .NET Framework. However, the
last version only runs on Microsoft Windows XP SP2, and does not contain all
features of version 2.0 of the .NET Framework.
 Microsoft's .NET Micro Framework is a .NET platform for extremely resource-
constrained devices. It includes a small version of the .NET CLR and supports
development in C# and debugging (in an emulator or on hardware), both using
Microsoft Visual Studio. It also features a subset of the .NET base class libraries
(about 70 classes with about 420 methods), a GUI framework loosely based on
Windows Presentation Foundation, and additional libraries specific to embedded
applications.
 Mono is an up-to-date implementation of the CLI and the .NET Base Class
Library (BCL), and provides additional functionality. It is dual-licensed under
free software and proprietary software licenses. Mono is actively being developed
by Novell, Inc. It includes support for ASP.NET, ADO.NET, and Windows
Forms libraries for a wide range of architectures (including iPhone, Wii and
others) and operating systems. It also includes C# and VB.NET compilers.
 CrossNet is an implementation of the CLI and portions of the .NET Base Class
Library (BCL). It is free software. It parses .NET assemblies and generates
standard C++ code, compilable with any ANSI C++ compiler on any platform.
 Portable.NET (part of DotGNU) provides an implementation of the Common
Language Infrastructure (CLI), portions of the .NET Base Class Library (BCL),
and a C# compiler. It supports a variety of CPUs and operating systems.

[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[

Visual Basic 

What is Visual Basic?

Visual Basic is a "visual programming" environment for developing


Windows (also Web now) applications. Visual Basic makes it
possible to develop complicated applications very quickly. The
programmer designs windows graphically, drags program elements
from the Visual Basic Toolbox and writes basic code for each
element. Visual Basic is "event-driven" which means that
procedures are called automatically when the end user chooses
menu items, clicks the mouse, moves objects on the screen, etc.

Why is Visual Basic popular?


Programmers have undergone a major change in many years of
programming various machines. For example, what could take days
to create an application in other programming languages like C, C++
could be done in hours with Visual Basic. Visual Basic provides
many interesting sets of tools to aid us in building exciting
applications. Visual Basic provides these tools to make our life far
more easier because all the real hard code is already written for us.

Visual Basic is not only a programming language but also a true


graphical development environment. This environment allows
programmers with little programming experience to quickly develop
powerful Windows applications. Visual Basic also has the ability to
develop programs that can be used as a front-end application to a
database system, serving as the user interface which collects user
input and displays formatted output in a more appealing and useful
form.

Visual Basic is very popular for the ease with which it allows the
programmer to create nice looking graphical programs with less
coding unlike many other languages that take thousands of lines of
programmer keyed code. As the programmer works in the graphical
environment much of the program code is automatically generated
by the Visual Basic program.

Areas of Use

Using Visual Basic's tools we can quickly translate an abstract idea


into a program design that we can actually see on the screen. VB
encourages you to experiment, revise, correct, and network your
design until the new project meets your requirements. However,
most of all, it inspires your imagination and creativity. Visual Basic
is ideal for developing applications that run on the Windows
operating system. Developing applications with VB can be said to
be a 3-step approach:

i) Design the appearance of application


ii) Assign property settings to the objects of the program
iii) Write the code to direct specific tasks at runtime

Visual Basic is used to develop applications in a number of different


areas. Some of them are listed below:

 Accounting
 Business
 Commerce
 Consulting
 Education
 Law
 Marketing and Sales
 Medicine
 Research
 Science

Many of the things that we do with Visual Basic really aren’t very
basic. The Visual Basic language is powerful, if you can imagine a
programming task, it can be accomplished using Visual Basic.

History of Visual Basic

Microsoft first released Visual Basic in 1987. It was the first visual
development tool from Microsoft, and it was to compete with C, C+
+, Pascal and other well-known programming languages. From the
start, Visual Basic wasn't a hit. It wasn't until release 2.0 that people
really discovered the potential of the language, and with release 3.0
it had become the fastest-growing programming language on the
market.

Below is the order and the approximate year in which a new version
of Visual Basic was released:

 1991, VB1 Debuts


 1992, VB2 Debuts
 1993, VB3 Debut
 1996, VB4 Debuts
 1997, VB5 Debuts
 1998, VB6 Debuts

 2001, VB. NET Debuts

[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]

nB gUru
"Wanting to be someone else is a waste of the person you are" – Kurt Cobain
dotNet -History of the IDE’s- NetBeans
with 4 comments

Hello,

Before we start, answer me 1 question! When did you for the 1st time came across Visual
Studio .NET and NetBeans!

In my locality/campus, people would say they came to know about the IDE’s between
2006-2007 and still there would be many, who don’t know what are these freaks, I mean
geeks talking about!

If I say that these IDE’s are just 10 years old, i.e. they came into being in 1996-97!
Probably no one would believe it, mainly sports lovers (who became passionate
programmers/developers) like me! B’coz, they were busy watching either Euro 1996 OR
Cricket World Cup 1996!

Actually, I was giving my 5th grade exams too Totally unaware of this fact, 10 years
later, I would be working on them! I don’t know, why its sounding so filmy, but its the
reality and I have accepted it, some might not have realized it yet!

So, lets go back to 1996-97, get a bit nostalgic and see what we missed!

dotNet -

Visual Studio was released in 1997, and it was Microsoft‘s first attempt at using the
same development environment for multiple languages, released in two editions.
Languages supported – Visual Basic 5.0 and Visual C++ 5.0, primarily for Windows
programming; Visual J++ 1.1 for Java and Windows programming; and Visual FoxPro
5.0 for database, specifically xBase programming.

Then, came into being Visual Studio 6.0, Visual Studio .NET (2002, 2003, 2005 and
finally, 2008). Gradually, the support for Java went from bad to worse, finally it was
removed.

NetBeans -

A project started by a group of students, made in C++ meant to be used in UNIX


environment, became “The Only IDE You Need!”, built completely in Java, thus portable
too!

It was earlier named Xelphi, i.e. Delphi-like IDE made for UNIX, that’s the reason for
the name. This became a business for Roman Stanek, who is a successful entrepreneur in
Czech Republic. In 1999, Sun Microsystems took over this project and it was their first
sponsored open source project, they decided to maintain the infrastructure, thus the
community came into being!

So, the roots lead to C++, so guys brush up your concepts, especially the basics of
programming in C/C++ and then, move to Java!

That’s what the historians say, now lets see the current status of these IDE’s!

Current Status -

Currently, dotNET Framework just focuses on Visual Basic, Visual C# (Sharp), Active
Server Pages, Game Development (XNA Game Studio, Dark GDK) and SQL Server
2005!

As support for Java got lesser and lesser with every release, finally getting removed from
dotNet Framework, on the other hand, NetBeans support for Java went from good to
better, and now, its the best!

References –

[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
General Questions – 01
August 5, 2006
1. Does C# support multiple-inheritance?
No. 
2. Who is a protected class-level variable available to?
It is available to any sub-class (a class inheriting this class). 
3. Are private class-level variables inherited?
Yes, but they are not accessible.  Although they are not visible or accessible via
the class interface, they are inherited.  
4. Describe the accessibility modifier “protected internal”.
It is available to classes that are within the same assembly and derived from the
specified base class.  
5. What’s the top .NET class that everything is derived from?
System.Object.  
6. What does the term immutable mean?
The data value may not be changed.  Note: The variable value may be changed,
but the original immutable data value was discarded and a new data value was
created in memory.  
7. What’s the difference between System.String and System.Text.StringBuilder
classes?
System.String is immutable.  System.StringBuilder was designed with the purpose
of having a mutable string where a variety of operations can be performed.  
8. What’s the advantage of using System.Text.StringBuilder over
System.String?
StringBuilder is more efficient in cases where there is a large amount of string
manipulation.  Strings are immutable, so each time a string is changed, a new
instance in memory is created. 
9. Can you store multiple data types in System.Array?
No.  
10. What’s the difference between the System.Array.CopyTo() and
System.Array.Clone()?
The Clone() method returns a new array (a shallow copy) object containing all the
elements in the original array.  The CopyTo() method copies the elements into
another existing array.  Both perform a shallow copy.  A shallow copy means the
contents (each array element) contains references to the same object as the
elements in the original array.  A deep copy (which neither of these methods
performs) would create a new instance of each element’s object, resulting in a
different, yet identacle object. 
11. How can you sort the elements of the array in descending order?
By calling Sort() and then Reverse() methods.  
12. What’s the .NET collection class that allows an element to be accessed using
a unique key?
HashTable.  
13. What class is underneath the SortedList class?
A sorted HashTable.  
14. Will the finally block get executed if an exception has not occurred?
Yes. 
15. What’s the C# syntax to catch any possible exception?
A catch block that catches the exception of type System.Exception.  You can also
omit the parameter data type in this case and just write catch {}.  
16. Can multiple catch blocks be executed for a single try statement?
No.  Once the proper catch block processed, control is transferred to the finally
block (if there are any).  
17. Explain the three services model commonly know as a three-tier application.
Presentation (UI), Business (logic and underlying code) and Data (from storage or
other sources). 

[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
1. Explain the .NET architecture.
2. How many languages .NET is supporting now? – When .NET was introduced
it came with several languages. VB.NET, C#, COBOL and Perl, etc. The site
DotNetLanguages.Net says 44 languages are supported.
3. How is .NET able to support multiple languages? – a language should comply
with the Common Language Runtime standard to become a .NET language. In
.NET, code is compiled to Microsoft Intermediate Language (MSIL for short).
This is called as Managed Code. This Managed code is run in .NET environment.
So after compilation to this IL the language is not a barrier. A code can call or use
a function written in another language.
4. How ASP .NET different from ASP? – Scripting is separated from the HTML,
Code is compiled as a DLL, these DLLs can be executed on the server.
5. Resource Files: How to use the resource files, how to know which language to
use?
6. What is smart navigation? – The cursor position is maintained when the page
gets refreshed due to the server side validation and the page gets refreshed.
7. What is view state? – The web is stateless. But in ASP.NET, the state of a page
is maintained in the in the page itself automatically. How? The values are
encrypted and saved in hidden controls. this is done automatically by the
ASP.NET. This can be switched off / on for a single control
8. Explain the life cycle of an ASP .NET page.
9. How do you validate the controls in an ASP .NET page? – Using special
validation controls that are meant for this. We have Range Validator, Email
Validator.
10. Can the validation be done in the server side? Or this can be done only in the
Client side? – Client side is done by default. Server side validation is also
possible. We can switch off the client side and server side can be done.
11. How to manage pagination in a page? – Using pagination option in DataGrid
control. We have to set the number of records for a page, then it takes care of
pagination by itself.
12. What is ADO .NET and what is difference between ADO and ADO.NET? –
ADO.NET is stateless mechanism. I can treat the ADO.Net as a separate in-
memory database where in I can use relationships between the tables and select
insert and updates to the database. I can update the actual database as a batch.

[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[
What is the difference between login controls and Forms authentication?

Latest answer: Login control provides form authentication. If we implement for


authentication through form authentication then we do it through code. On the other
hand, login control allows the easy implementation...............
Read answer

What is Fragment Caching in ASP.NET?


Latest answer: Fragment caching allows to cache specific portions of the page rather
than the whole page. It is done by implementing the page in different parts............ 
Read answer

What is partial classess in .net?

Latest answer: When there is a need to keep the business logic separate from the User
Interface or when there is some class which is big enough to have multiple number of
developers............
Read answer

Explain how to pass a querystring from an .asp page to aspx page.

Latest answer: FromHTMLinasppage:<ahref="abc.aspx?qstring1=test">Test Query


String</a>
From server side code: <%response.redirect "webform1.aspx?id=11"%>...............
Read answer

What is a ViewState?

Latest answer: If a site happens to not maintain a ViewState, then if a user has entered
some information in a large form with many input fields and the page is refreshes, then
the values filled up in the form are lost...........
Read answer

What is the difference between src and Code-Behind?

Latest answer: With the ‘src’ attribute, the source code files are deployed and are
compiled by the JIT as needed.
Though the code is available to everyone with an access to the server (NOT anyone on
the web)................
Read answer

What is the difference between URL and URI?

Latest answer: A URL (Uniform Resource Locator) is the address of some resource on
the Web. A resource is nothing but a page of a site. There are other type of resources than
Web pages, but that's the easiest conceptually...........
Read answer

What is the Pre-Compilation feature of ASP.NET 2.0?

Latest answer: Previously, in ASP.NET, the pages and the code used to be compiled
dynamically and then cached so as to make the requests to access the page extremely
efficient............
Read answer
How can we create custom controls in ASP.NET?

Latest answer: Custom controls are user defined controls. They can be created by
grouping existing controls, by deriving the control from
System.Web.UI.WebControls..........
Read answer

What is an application domain?

Latest answer: It's a way in CLR to maintain a boundary between various applications to
ensure that they do not interfere in working of any other application...........
Read answer

Explain the two different types of remote object creation mode in .NET. [Hint
SAO and CAO]

Latest answer: SAO Server Activated Object (call mode): lasts the lifetime of the server.
They are activated as SingleCall/Singleton objects. It makes objects stateless...........
Read answer

Describe SAO architecture of Remoting.

Latest answer: Remoting has at least three sections:-

1. Server
2. Client: This connects to the hosted remoting object
3. Common Interface between client and the server .i.e. the channel..........
Read answer

Explain Singleton architecture of Remoting.

Latest answer: Singleton architecture is to be used when all the applications have to use
or share same data...........
Read answer

Define LeaseTime, SponsorshipTime, RenewOnCallTime,


LeaseManagePollTime.

Latest answer: The LeaseTime property protects the object so that the garbage collector
does not destroy it as remoting objects are beyond the scope of the garbage collector.
Every object created has a default leasetime for which it will be activated..........
Read answer

Briefly explain how to specify remoting parameters using config files.


Latest answer: The remoting parameters can be specified through both programming
and in config files. All the settings defined in config files are placed under
<system.runtime.remoting>...........
Read answer

What is marshalling? Explain types of marshalling.

Latest answer: Marshaling is a process of transforming or serializing data from one


application domain and exporting it to another application domain...........
Read answer

What is ObjRef object in remoting?

Latest answer: ObjRef is a searializable object returned by Marshal() that knows about
location of the remote object, host name, port number, and object name........
Read answer

Explain the steps of acquiring a proxy object in web services.

Latest answer: Every service listed has a URI pointing to the service's DISCO or WSDL
document, which is needed to access the webservice and its 'webmethod" methods..........
Read answer

Explain the steps to create a web services and consume it.

Latest answer: Create a new website by selecting "ASP.NET Web Site" and giving it a
suitable name. service.cs file appears inside the solution with a default webmethod named
as "HelloWorld()"........
Read answer

Explain the difference between cache object and application object.

Latest answer: Application Object: Application variable/object stores an Object with a


scope of availability of the entire Application unless explicitly destroyed.............
Read answer

What is Cache Callback in Cache?

Latest answer: The cache object has dependencies e.g. relationships to the file it stores.
Cache items remove the object when these dependencies change. As a work around we
would need to simply execute a callback method............
Read answer

What is Scavenging?
Latest answer: A process where items are removed from cache in order to free the
memory based on their priority. A property called "CacheItemPriority" is used to figure
out the priority of each item inside the cache...........
Read answer

Explain the types of Caching using Cache object of ASP.NET.

Latest answer: Page output: Is used to fetch information or data at page level. It is best
used when the site is mainly static. Used by declaring the output page directive............
Read answer

Show with an example how to Cache different version of same page using
ASP.NET Cache object.

Latest answer: The ways to cache different versions on the same page using ASP.NET
cache object is using OutputCache object............
Read answer

Explain how to implement Fragment Cache.

Latest answer: Fragment cache is to store user controls individually within a web form
in cache instead of the whole webform as such. The idea is to simply have different cache
parameters for different user controls.............
Read answer

Explain the various modes of storing ASP.NET session.

Latest answer: Types of sessions: InProc: The default way to use sessions. InProc is the
fastest way to store and access sessions...........
Read answer

What are the benefits and limitations of using hidden fields?

Latest answer: Advantages: Easy to implement, Hidden fields are supported by all


browsers, Enables faster access of information because data is stored on client
side............
Read answer

What are the benefits and limitations of using Hidden Frames?

Latest answer: Advantages: Hidden frames allow you to cache more than one data
field, The ability to cache and access data items stored in different hidden forms...........
Read answer

What are benefits and limitations of using Cookies?


Latest answer: Advantages: They are simple to use. Light in size, thus occupy less
memory. Stores server information on client side. Data need not to be sent back to
server........
Read answer

What is QueryString and what are benefits and limitations of using


querystring?

Latest answer: Querystring is way to transfer information from one page to another
through the URL........
Read answer

What is Absolute and Sliding expiration in .NET?

Latest answer: Absolute and sliding expiration are two Time based expiration strategies.
Absolute Expiration: Cache in this case expires at a fixed specified date or time..............
Read answer

Explain the concepts and capabilities of cross page posting.

Latest answer: Cross-page posting is done at the control level. It is possible to create a
page that posts to different pages depending on what button the user clicks on. It is
handled by done by changing the postbackurl property of the controls..........
Read answer

Explain how to access ViewState value of this page in the next page.

Latest answer: PreviousPage property is set to the page property of the nest page to
access the viewstate value of the page in the next page. Page poster =
this.PreviousPage;..........
Read answer

What is SQL Cache Dependency in ASP.NET?

Latest answer: SQL Cache Dependency in ASP.NET: It is the mechanism where the
cache object gets invalidated when the related data or the related resource is
modified.........
Read answer

Explain the concepts of Post Cache Substitution in .NET

Latest answer: Post Cache Substitution: It works opposite to fragment caching. The
entire page is cached, except what is to be kept dynamic. When [OutputCache] attribute
is used, the page is cached............
Read answer
Explain the use of localization and Globalization.

Latest answer: Users of different countries, use different languages and others settings
like currency, and dates. Therefore, applications are needed to be configurable as per the
required settings based on cultures, regions, countries........
Read answer

Explain the concepts of CODE Page approach. What are the disadvantages of
this approach?

Latest answer: Code Page was used before Unicode came into existence. It was a
technique to represent characters in different languages..........
Read answer

What are resource files and explain how do we generate resource files?

Latest answer: Resource files are files in XML format. They contain all the resources
needed by an application. These files can be used to store string, bitmaps, icons,
fonts........
Read answer

What are Satellite assemblies and how to generate Satellite assemblies?

Latest answer: To support the feature of multiple languages, we need to create different
modules that are customized on the basis of localization. These assemblies created on the
basis of different modules are knows as satellite assemblies...........
Read answer

Define AL.EXE and RESGEN.EXE.

Latest answer: Al.exe: It embeds the resources into a satellite assembly. It takes the
resources in .resources binary format.......
Read answer

Explain the concepts of resource manager class.

Latest answer: ResourceManager class: It provides convenient access to resources that


are culture-correct. The access is provided at run time.........
Read answer

What is Windows communication foundation, WCF?

Latest answer: WCF is a framework that builds applications that can inter-communicate
based on service oriented architecture consuming secure and reliable web
services.............
Read answer
Explain the important principle of SOA.

Latest answer: A service-oriented architecture is collection of services which


communicate with one another other......
Read answer

Explain the components of WCF - Service class, Hosting environment, END


point.

Latest answer: WCF Service is composed of three components: Service class: It


implements the service needed, Host environment: is an environment that hosts the
developed service.............
Read answer

Difference between WCF and Web Services.

Latest answer: WCF can create services similar in concept to ASMX, but has much
more capabilities. WCF is much more efficient than ASP.Net coz it is implemented on
pipeline............
Read answer

What are different bindings supported by WCF?

Latest answer: BasicHttpBinding, WSHttpBinding, WSDualHttpBinding.......


Read answer

What is duplex contract in WCF?

Latest answer: Duplex contract: It enables clients and servers to communicate with each
other. The calls can be initiated independently of the other one.............
Read answer

Explain the different transaction isolation levels in WCF.

Latest answer: Read Uncommitted: - Also known as Dirty isolation level. It makes sure
that corrupt Data cannot be read. This is the lowest isolation level............
Read answer

What are Volatile and Dead letter queues?

Latest answer: Volatile Queues: There are scenarios in the project when you want the
message to deliver in proper time. The timely delivery of message is very more important
and to ensure they are not lost is important too. Volatile queues are used for such
purposes.............
Read answer
What is Windows workflow foundation?

Latest answer: Windows Workflow Foundation (WF): It is a platform for building,


managing and executing workflow-enabled applications, for designing and implementing
a programming model ..........
Read answer

Explain the types of Workflow in Windows Workflow Foundation.

Latest answer: There are 3 types of workflows in WWF: Sequential Workflow: The
sequential workflow style executes a set of contained activities in order, one by one and
does not provide an option to go back to any step...........
Read answer

What are XOML files? Explain their uses.

Latest answer: XOML is an acronym for Extensible Object Markup Language. XOML
files are the markup files. They are used to declare the workflow and are then compiled
with the file containing the implementation logic..............
Read answer

How to make an application offline in ASP.NET 2.0.

Latest answer: Microsoft's Internet Information Services web server software is used to
make an application offline. The IIS is instructed to route all incoming requests for the
web site to another URL automatically........
Read answer

What are script injection attacks?

Latest answer: Script injection attacks called Cross-site scripting (XSS) attacks exploit
vulnerabilities in Web page validation by injecting client-side script code.............
Read answer

What is Authentication in ASP.NET?

Latest answer: Authentication is the process of verifying user’s details and find if the
user is a valid user to the system or not. This process of authentication is needed to
provide authority to the user........
Read answer

What is Authorization in ASP.NET?

Latest answer: Authorization is a process that takes place based on the authentication of
the user. Once authenticated, based on user’s credentials, it is determined what rights des
a user have...........
Read answer

What is the difference between login controls and Forms authentication?

Login controls are part of ASP. Net’s UI controls collection which allows users to enter
their username and password to login to a website/application. They provide login
solution without the need of writing code...........
Read answer

What is Fragment Caching in ASP.NET?

Fragment caching does not cache a WebForm, rather it allows for caching of individual
user controls within a Web Form, where each control can have different cache duration
and behavior...........
Read answer

What is partial classess in .net?

.Net2.0 supports the concept of partial classes which is unlike the concept of one class
one file. In .Net technology, one can define a single class over multiple files using the
concept of partial classes............
Read answer

Explain how to pass a querystring from an .asp page to aspx page.

Yes you can do it using a hyperlink< BR><ahref="Abc.aspx?name=test">Click to go to


aspx </a>.............
Read answer

Overview of the .NET Compact Framework

.NET Compact Framework is a scaled down versions of .NET framework for supporting
Windows CE based mobile and embedded devices like mobile phones...............

What is Language Integrated Query (LINQ)?

LINQ is a set of extensions to .NET Framework that encapsulate language integrated


query, set and other transformation operations...................

Next>>

Also Read  

ASP.NET DataList Control


Using the DataList control, Binding images to a DataList control dynamically, Displaying data
using the DataList control, Selecting, editing and delete data using this control, Handling the
DataList control events..........

ASP.NET Methodologies

ASP.NET attempts to make the web development methodology like the GUI development
methodology by allowing developers to build pages made up of controls similar to a GUI. Server
controls in ASP.NET function similarly to GUI controls in other environments..........

Problems ASP.NET Solves

Microsoft developed ASP.NET, which greatly simplifies the web development methodology...........

ASP.NET issues & options

The truth is that ASP.NET has several issues that need to be addressed..........

Explain the advantages of ASP.NET

Web application exists in compiled form on the server so the execution speed is faster as
compared to the interpreted scripts.........

What Is ASP.NET 2.0 AJAX?

AJAX-style communications between client and server. This communication is over web
services. Asynchronous communication. All client-to-server communication in the
ASP.NET 2.0 AJAX framework is asynchronous................

The components in the ASP.NET 2.0 AJAX packaging

ASP.NET AJAX Futures Community Technology Preview (CTP) — The ASP.NET 2.0 AJAX
framework contains a set of functionality that is experimental in nature. This functionality
will eventually become integrated with the RTM/Core code.

Potential benefits of using Ajax

AJAX makes it possible to create better and more responsive websites and web
applications...............

Potential problems with AJAX

Search engines may not be able to index all portions of your AJAX application site.........

What Is ASP.NET AJAX?

ASP.NET AJAX is the name of Microsoft’s AJAX solution, and it refers to a set of client
and server technologies that focus on improving web development with Visual
Studio...............
Balancing Client and Server Programming with ASP.NET AJAX

With AJAX, much of the logic surrounding user interactions can be moved to the client.
This presents its own set of challenges. Some examples of AJAX use include streaming
large datasets to the browser that are managed entirely in JavaScript..................

Understanding Anonymous Types

Anonymous types defined with var are not VB variants. The var keyword signals the
compiler to emit a strong type based on the value of the operator on the right side.
Anonymous types can be used to initialize simple types like integers and strings but
detract modestly from clarity and add little value..............

Model View Controller

We will learn about MVC design patterns, and how Microsoft has made our lives easier
by creating the ASP.NET MVC framework for easier adoption of MVC patterns in our
web applications............... 

MVC Design

MVC, which stands for Model View Controller, is a design pattern that helps us achieve
the decoupling of data access and business logic from the presentation code , and also
gives us the opportunity to unit test the GUI effectively and neatly, without worrying
about GUI changes at all..........

You might also like