46 DOT.NET interview questions and answers - freshers, experienced

Describe the programming model of a windows service - Windows services are based on the class that is inherited from System.ServiceProcess.ServiceBase class........
Explain the states of a windows service application - running, paused, stopped and pending.......
Explain the types of window services - Win32OwnProcess, Win32ShareProcess......
Explain the steps to create a windows service - Steps to create a windows service:......
Describe how to add functionality to a service application - It is done by overriding the functions of Base class......
Explain the need of installer in a service application - The installer allows the registration of a service on the system and let the Service Control Manager.....
Explain the steps to attach a debugger to a service application - Steps to attach a debugger to the application:......
Explain how COM+ related to the DNA architecture - COM+ is the core service in all the services of window DNA architecture.......
Describe the use of COM+ services - JIT Activation, Queued components, object pooling......
What is a Serviced component? - A serviced component is a class that is inside all the CLS-complaint languages.......
Answer - How to load the contents of an XML file into an XMLDocument object......
Answer - Explain how to read the contents of an XML document using XMLTextReader......
Answer - Explain how to write data to an XML file.......
Answer - Explain how XPathNavigator read data from an XMLDocument.......
What is an XML Web service? - XML Web Service is a unit of code that can be accessed independent of platforms and systems.......
What is an XML Web service? - XML Web Service is a unit of code that can be accessed independent of platforms and systems.....
Describe the steps to deploy a web service - Using xcopy or Publish wizard copy the file to the destination server........
Describe the components that are published when a web service is deployed - Asmx file: This is the main service file.......
Describe what does the .disco file contain - It defines a document format that enables discovery of the web services.....
Steps to configure discovery information for an XML web service - The .disco file contains links to resources that define the specific XML web service.....
Explain the steps to consume a web service in a client application - Add a web reference to the application......
Describe the steps to enable transactions in a web method - You have to use TransactionOption property of the WebMethod attribute.......
Explain the deployment features of the .NET Framework - No-impact applications, Private components by default, Controlled code sharing, Side-by-side versioning, XCOPY deployment and replication, On-the-fly updates, Integration with the Microsoft Windows Installer, Enterprise deployment, Downloading and caching, Partially trusted code......
What are Merge Module projects? - Merge Module projects enable creation and deployment of code that can be shared by multiple applications.......
Explain the format of the assembly version stored in the AssemblyInfo file - AssemblyVersion/AssemblyFileVersion......
Answer - What are User-defined types in .NET?......
What are the Enumerations? How to create Enumerations in C#.NET? - An enumeration is a special type of collection in the .NET Framework......
Define Stream class in .NET. Explain with an example using C#.NET? - The Stream class gives a view of various types of input and output. Streams involve three fundamental operations:......
Explain common Stream types in Net - FileStream, MemoryStream, StreamReader, StreamWriter.....
Explain how to compress data with a compression Stream - Compression streams write to another stream.......
Answer - Explain how to Throw and Catch Exceptions......
Use StringBuilder class instead of the String class - Whenever any of the methods of String class is used to modify the string......
Explain why we should close and dispose resources in a Finally block instead of Catch block - Catch block gets called only when an exception occurs or is explicitly thrown.......
What is an Interface in NET? - Interface contains only the declaration for its abstract members (events, methods, properties)......
Define most commonly used interfaces in .Net Framework - IComparable, IDisposable, IConvertible, ICloneable, IEquatable, IFormattable......
Answer - Explain how to create and consume a Generic type.....
What is Type Forwarding in NET? - Type forwarding is a technique to move types from one assembly to another......
What is SOAPFormatter? - It is an xml based serialization technique which is used to serialize and deserialize objects and data across networks.......
Explain why we use XML Serialization - Serialization allows persisting objects. XML serializations stores objects in form of XML which has become a storage standard......
Explain how to use XML to Serialize an object - Use the namespace “System.Xml.Serialization”......
Explain how to use XML to deserialize an object - XmlSerializer srl = new XmlSerializer(typeof(Class1));......
Debug Build vs. Release build in .NET - In Debug mode, You can use the development environment's integrated debugging functions.......
What is Code Access Security? Describe the purpose of CAS - Code access security is a mechanism to help protect computer systems from malicious code......
What is a Permission? What is a Permission Set? - Permission is a rule to enforce restriction on a piece of managed code.......
What are code groups in .NET? - Code group is a logical grouping of code that follows some given conditions for membership.......