private void ButtonPoint_Click(object sender, EventArgs e) { if (TextBoxResult.Text.Contains(".") || CheckIfTextBoxResultIsString()) { return; } TextBoxResult.AppendText("."); }
private void ButtonTask_Click(object sender, EventArgs e) { TextBoxResult.Clear(); var words = TextBoxSource.Text.Split(new[] { "\n" }, StringSplitOptions.RemoveEmptyEntries); var result = FormUtils.RunAlgorithm(words); foreach (var index in result) { TextBoxResult.AppendText(words[index] + '\n'); } }
private void HelperNumberButtonsToSetValue(string ValueToSet) { if (TextBoxResult.Text == "0") { TextBoxResult.Clear(); TextBoxResult.Text = ValueToSet; return; } if (!(TextBoxResult.Text.Contains(".")) && CheckIfTextBoxResultIsString()) { TextBoxResult.Text = "0"; return; } TextBoxResult.AppendText(ValueToSet); }