private string SampleNameInputValidate(string str) { try { Model.SampleName.Value = SampleName.Create(str); return null; } catch (Exception ex) { Model.SampleName.Value = SampleName.NullObject; return ex.Message; } }
private string sampleNameValidate(string str) { try { Model.SampleName.Value = SampleName.Create(str); return(null); } catch (Exception ex) { Model.SampleName.Value = SampleName.NullObject; return(ex.Message); } }
public MessageBrokerViewModel(IEventAggregator eventAggregator) { MessageBrokerCommand.Subscribe(_ => Reactive.Bindings.Notifiers.MessageBroker.Default.Publish <SampleNameChange>(new SampleNameChange(SampleName.Create(MessageBrokerName.Value), ViewName.Create("MessageBrokerView")))).AddTo(DisposeCollection); PubSubEventCommand.Subscribe(_ => eventAggregator.GetEvent <SampleNameChangeEvent>().Publish(new SampleNameChange(SampleName.Create(MessageBrokerName.Value), ViewName.Create("MessageBrokerView")))).AddTo(DisposeCollection); }