What is the difference between Finalize and Dispose?

Class instances often encapsulate control over resources that are not managed by the runtime, such as window handles (HWND), database connections, and so on. Therefore, you should provide both an explicit and an implicit way to free those resources. Provide implicit control by implementing the protected Finalize Method on an object (destructor syntax in C# and the Managed Extensions for C++). The garbage collector calls this method at some point after there are no longer any valid references to the object. In some cases, you might want to provide programmers using an object with the ability to explicitly release these … Click here to continue reading.

What is difference between canche.insert and cache.add method

The Add and Insert methods have the same signature, but there are subtle differences between them. First, calling the Add method returns an object that represents the cached item, while calling Insert does not. Second, their behavior is different if you call these methods and add an item to the cache that is already stored there. The Insert method replaces the item, while the Add method fails.

What is Globalization and Localization?

Globalization is the process of creating an application that meets the needs of users from multiple cultures. It includes using the correct currency, date and time format, calendar, writing direction, sorting rules, and other issues. Accommodating these cultural differences in an application is called localization.Using classes of System.Globalization namespace, you can set application’s current culture. This can be achieved by using any of the following 3 approaches. Detect and redirect Run-time adjustment Using Satellite assemblies.

What is a Resource File?

A resource file may contain a collection of icons, menus, dialog boxes, strings tables, user-defined binary data and other types of items. Once compiled into a suitable format, a resource file can be embedded directly into an executable file, producing a single EXE containing both code and resources. At run-time, the application can use the resource items in the embedded file. The process of creating a resource is straightforward, and is similar to compiling a PowerBASIC program. While resource files are still supported, usage of the #RESOURCE metastatement simplifies adding resources to your program. With the #RESOURCE metastatement you can … Click here to continue reading.

What is Serialization in .NET?

The serialization is the process of converting the objects into stream of bytes. they or used for transport the objects(via remoting) and persist objects(via files and databases) When developing smaller applications that do not have a database (or other formal storage mechanism) or data that doesn’t need to be stored in a database (such as the state of a web application), you often still would like to save the data for later retrieval. There are many ways to do this, but many of them are subject to a lot of extra code (work) and extra time spent debugging. With .NET, … Click here to continue reading.