validation c# code example
Example: C# validaion
public string Name
{
get { return Name; }
set {
if(string.IsNullOrEmpty(value))
throw new ArgumentException
("Name cannot be blank","Name");
Name = value;
}
}