public object GetDetails() { var dialog = new DetailsDialog(); if (dialog.ShowDialog() == true) { return(new { Name = dialog.SongName, Artist = dialog.SongArtist, Genre = dialog.SongGenre }); } return(null); }
private void NewDetailsDialog_Click(Object sender, RoutedEventArgs e) { var Details = new DetailsDialog(); if (Details.ShowDialog() == true) { Revenue.Text = String.Format("{0}", Details.Revenue); CGOS.Text = String.Format("{0}", Details.CGOS); Percent.Text = String.Format("{0}", Details.Percent); Result.Text = String.Format("{0}", AC.GrossMargin(Convert.ToDecimal(Details.Revenue), Convert.ToDecimal(Details.CGOS), Convert.ToDecimal(Details.Percent))); } }
/// <summary> /// Opens a Details dialog. /// </summary> private void OnDetails(object sender, EventArgs e) { // This is not allowed while the Solver is busy. if (State != SolverState.Ready && State != SolverState.Finished) { return; } DetailsDialog form = new DetailsDialog(this.AriadneSettingsSource); form.ShowDialog(this); }