Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.DataImporter/HeuristicLab.DataImporter.Command/View/ProgrammableColumnCommandView.cs @ 6133

Last change on this file since 6133 was 6133, checked in by gkronber, 13 years ago

#1471: imported generic parts of DataImporter from private code base

File size: 1.1 KB
Line 
1using System;
2using System.Collections.Generic;
3using System.ComponentModel;
4using System.Data;
5using System.Drawing;
6using System.Text;
7using System.Windows.Forms;
8
9namespace HeuristicLab.DataImporter.Command.View {
10  public partial class ProgrammableColumnCommandView : HeuristicLab.DataImporter.Data.CommandBase.CommandViewBase {
11    private ProgrammableColumnCommandView() {
12      InitializeComponent();
13      this.expressionTextBox.Text = "A";
14    }
15
16    public ProgrammableColumnCommandView(AddNewProgrammableColumnCommand command)
17      : this() {
18      this.Command = command;
19    }
20
21    public new AddNewProgrammableColumnCommand Command {
22      get { return (AddNewProgrammableColumnCommand)base.Command; }
23      set { base.Command = value; this.UpdateCommand(); }
24    }
25
26    public string Expression {
27      get { return expressionTextBox.Text; }
28    }
29
30    private void UpdateCommand() {
31      if (Command != null)
32        Command.Expression = this.expressionTextBox.Text;
33    }
34
35    private void expressionTextBox_TextChanged(object sender, EventArgs e) {
36      this.UpdateCommand();
37    }
38  }
39}
Note: See TracBrowser for help on using the repository browser.