private void OnPropertyErrorsChanged(string p) { if (ErrorsChanged != null) { ErrorsChanged.Invoke(this, new DataErrorsChangedEventArgs(p)); } }
private void RaiseErrorsChanged(string propertyName) { if (ErrorsChanged != null) { ErrorsChanged.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); } }
/// <summary> /// Fire ErrorsChanged Event for given property and call OnPropertyChanged for property HasErrors. /// </summary> /// <param name="propertyName">Property name to fire event for</param> protected virtual void OnErrorsChanged(string propertyName) { if (ErrorsChanged != null) { ErrorsChanged.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); } OnPropertyChanged(nameof(HasErrors)); }
/// <summary> /// The ErrorChaged handler which will be on each property. /// </summary> /// <param name="propertyName"></param> public void PropertyErrorsChanged(string propertyName) { if (ErrorsChanged != null) { var evtargs = new DataErrorsChangedEventArgs(propertyName); ErrorsChanged.Invoke(this, evtargs); } }
private void RefreshErrors() { if (ErrorsChanged != null) { var properties = this.GetType().GetProperties(); foreach (var p in properties) { ErrorsChanged.Invoke(this, new DataErrorsChangedEventArgs(p.Name)); } } }
public void OnErrorsChanged([CallerMemberName] string propertyName = null) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
public BindableBaseWithErrorsContainer() { ErrorsContainer = new ErrorsContainer <string>( x => ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(x))); }
public void RaiseErrorChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
protected void OnErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); NotifyPropertyChanged(nameof(Errors), nameof(HasErrors)); }
private void OnErrorsChanged(DataErrorsChangedEventArgs e) { ErrorsChanged?.Invoke(this, e); }
// HELPER FOR RAISING EVENTS PROGRAMATICALLY protected void OnErrorsChanged([CallerMemberName] string propertyName = "") { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
private void ChangedErrorsEvents(object sender, DataErrorsChangedEventArgs e) { ErrorsChanged?.Invoke(this, e); OnPropertyChanged(nameof(CanCreate)); }
private void OnErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
private void OnErrorsChanged([System.Runtime.CompilerServices.CallerMemberName] string propertyName = "") { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
private void RaiseErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); SaveCommand.RaiseCanExecuteChanged(); }
private void OnErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); OnPropertyChanged(nameof(DoesNotHaveErrors)); }
protected void RaiseErrorsChanged(DataErrorsChangedEventArgs args) { ErrorsChanged?.Invoke(this, args); RaisePropertyChanged("HasErrors"); }
protected void RaiseErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); RaisePropertyChanged(nameof(HasErrors)); }
private void RaiseErrorsChanged([CanBeNull] string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
private void OnCustomUIErrorsChanged(object sender, DataErrorsChangedEventArgs e) { ErrorsChanged?.Invoke(this, e); OnPropertyChanged(nameof(DoesNotHaveErrors)); }
/// <summary> /// Raises the errors changed. /// </summary> /// <param name="name">The name.</param> protected void RaiseErrorsChanged(string name) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(name)); }
private void ErrorsChangedHandler(object sender, DataErrorsChangedEventArgs e) => ErrorsChanged.Invoke(sender, e);
/// <summary> /// Raises the ErrorsChanged event. /// </summary> /// <param name="propertyName">The name of the property that the error relates to.</param> public void OnErrorsChanged(string propertyName) => ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName));
protected void NotifyErrorsChanged(string nombre) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(nombre)); }
public void AddError(string propertyName, string errorText) { _Errors[propertyName] = errorText; ErrorsChanged?.Invoke(this, EventArgs.Empty); }
/// <summary> /// Raises the <see cref="E:ErrorsChanged"/> event. /// </summary> /// <param name="e">The <see cref="System.ComponentModel.DataErrorsChangedEventArgs"/> instance containing the event data.</param> protected virtual void OnErrorsChanged(DataErrorsChangedEventArgs e) { ErrorsChanged?.Invoke(this, e); }
private void OnErrorsChanged(string propertyName) { this.RaisePropertyChanged(nameof(HasErrors)); ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
protected virtual void OnErrorsChanged(object sender, DataErrorsChangedEventArgs e) => ErrorsChanged?.Invoke(sender, e);
protected virtual void OnErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName)); }
protected virtual void OnErrorsChanged(string propertyName) { ErrorsChanged?.Invoke(this, new DataErrorsChangedEventArgs(propertyName));// if the ErrorsChanged is not null, invoke it and pass the object and dataerrorchangeeventarges with the propertyName }