Monday, October 20, 2008

"Ambigious Match Found" - Works fine in develoment environment

A few days ago I ran into this problem while i was working for a project.Everything was working well in development environment.But when this was deployed in the production server things were not going as expected. After consulting with sohan and with the help of asp.net forum we figured out that my aspx page contained TextBox control "Email" and string variable email in the codebehind file

private string email;

and these two variables were raising ambiguity in the production environment though the two variables were of different types and of different casing.

After changing name of one variable the page was not raising any exception in the production environment.

Sunday, May 25, 2008

Difference between Managed & Unmanaged Code

This might be old topic. But anybody who is looking for what managed and unmanaged code mean can find it here.

Tuesday, May 13, 2008

Get value of a class property using reflection in .net

This site contains a simple example how to get property value of a class using reflection.

Friday, May 9, 2008

Declaring Attribute Class In .Net

Adding a attribute class in .net is very simple.It's just a class declaration which inherits System.Attribute and is marked with AttributeUsage attribute.

[AttributeUsage(AttributeTargets.All)]
class MyAttributeClass : System.Attribute
{
//variables
//methods
}

once you declare this class you can use this as attribute in another class like following one


Class MySampleClass
{
[MyAttributeClass]
public void Dosomething()
{

}
}
More to come later...........