Friday, December 26, 2008

Seasons Greeting

Wish you all a very Happy 2009!

Saturday, June 28, 2008

Howto: Strong naming a prebuilt assembly

If you need to apply a strong name to an assembly that was provided, already compiled, to you and you don't have the source, What you will do?

You first will need to produce the Microsoft intermediate language (MSIL) for the assembly using the ILDASM.EXE utility, then use an assembly key file to sign that MSIL into a new DLL using the ILASM.EXE utility.
Obtain the MSIL for the provided assembly From a VS.NET command prompt, enter the following: c:\>ildasm providedAssembly.dll /out:providedAssembly.il
Rename/Backup the original assembly or save it with a .bak extension. Once this is done.
Create a new assembly from the MSIL output and your assembly keyfile Assuming you already have an assembly key pair file ,do the following from a VS.NET command prompt:

c:\>ilasm providedAssembly.il /dll /key=keypair001.snk

Alas, you have an assembly strong named.
(Source:
http://www.andrewconnell.com/blog/archive/2004/12/15/772.aspx)

Tuesday, June 10, 2008

Reporting services 2005 - Could not load file or Assembly 'Microsoft.ReportingServices.Designer

"Could not load file or Assembly 'Microsoft.ReportingServices.Designer, version=9.0.242.0, CUlture=neutral, publickeyToken='' or one of its dependencies. The system cannot fidn the file specified" . If you have encountered this error while creating Report server project in visual studio 2005, here is the solution.

  1. Make sure the business intelligence addin (as part of SQL server 2005 express edition(SQLEXPR_TOOLKIT.EXE) is installed in the same directory as you have installed the visual studio 2005.
  2. By default the addin is installed in C:\
  3. Copy the contents of C:\Program Files\Microsoft Visual Studio 8\Common7\IDE to the same directory as visual studio 2005 installtion folder ( for ex. D:\Program Files\Microsoft Visual Studio 8\Common7\IDE if the visual studio installation is in D: drive)
  4. After copying the content to specific folders, we have to re register the reports package.
  5. For registering the package, Click on start button and then click Run.In the Open text box, type the following, and then press ENTER:
    "\Common7\IDE\devenv.exe" /setup /resetskippkgs ( is visual studio installationg path for ex. D:\Program Files\Microsoft Visual Studio 8\)
  6. Click OK.
  7. Click Start, and then click Run.
    In the Open text box, type the following, and then press ENTER:
    "Folder Path\Common7\IDE\devenv.exe" /resetskippkgs
    Click OK. If there are no errors, Visual Studio .NET or Visual Studio 2005 starts with no warnings and the problem is resolved

Saturday, January 5, 2008

OOPS Overview

Object-oriented programming (OOP) is a programming paradigm that uses "objects" and their interactions to design applications and computer programs.

Fundamental concepts

Class: A class defines the characteristics of a thing. namely the state (attributes, fields or properties) and behavior (methods, operation or features). For example a Vehicle is an example of a class.
Object: An object is an instance of the class. In the case of our example, a car can be considered as an object of the class vehicle.

The different OOPS techniques are
1. Abstraction
2. Encapsulation
3. Polymorphism
4. Inheritence

Abstraction:

This is the process of hiding the complexity and the inner workings of a class, so that users dont have to know how it operates.

Encapsulation:

The process of every object that binds togeter the data and code it required to operate upon.

Polymorphism

This the term given to different objects being able to perform the same action but through different implementation. The dynamic polymorphism or Run time polymorphism means, complier would comes to know which method to execute, at the run time not in compile time.We can Implement the Run time polymorphism by using the Override Key word.And in the base class that method should be a virtual method. The static polymorphism or compile time polymorphism means, compiler knows which method to execute at compile time. We can implement compile time polymorphism using function overloading or operator overloading.

Inheritance

The inheritance defines how classes can be related to one another and share the characteristics. It is the property by which an object can get the properties and behavior of other object.
A class that is inherited is called a base class. A class which is inheriting another class is called a derived class. When a class inherits another class, members of the base class become the members of the derived class. The general form of inheritance is:-

class derivedClassName : BaseClassName
{
};

Tuesday, January 1, 2008

A brand new year 2008

A brand new year has born. Hopefully this new year brings in happines and cheer to everyone.