I am new to windows phone 7 development platform.I am trying to do validation for textbox input. On debugging ,in case of invalid input , I get the error "exception was unhandled".How to correct this?This code works fine for silverlight application.
TextBox Text="{Binding Name, Mode=TwoWay, NotifyOnValidationError=True, ValidatesOnExceptions=True}" />
private string _name;  
public String Name  
        {  
            get   {   return _name; }  
            set {
                if (string.IsNullOrEmpty(value))
                {
                    throw new Exception("invalid name");
                }
                _name = value;
                OnPropertyChanged("Name");
            }
        }