//------------ public DtcActivityForm() { InitializeComponent(); dgvDeliveryOrders.DataSource = Display; DGVDel = new DgvHelper(dgvDeliveryOrders, this.Name, true); helper.Add(DGVDel); helper.handleCellSelected += new CellSelectEventHandler(h_handleCellSelected); handleDtcMessageReceived = new IncomingDtcMessageEventHandler(Instance_handleDtcMessageReceived); handleCusipSelected = new CusipSelectEventHandler(OnCusipSelected); DtcChannel.Instance.handleDtcMessageReceived += handleDtcMessageReceived; DtcChannel.Instance.handleCusipSelected += handleCusipSelected; }
private void MainForm_Load(object sender, EventArgs e) { MyMessageBox.MessageBoxEvent += SetMessageBox; DgvHelper.InitDgv(gridView1, @"test"); HtmlModel hm = new HtmlModel("http://x3.1024lualu.pw", "pw/thread.php?fid=16&page=", "//div[@class='tpc_content']/img", "href", ""); HtmlModelTool.htmlModel = hm; this.htmlModelBindingSource.DataSource = HtmlModelTool.htmlModel; this.BasePathTextBox.DataBindings.Add(new Binding("Text", this.htmlModelBindingSource, "BasePath", true)); this.BasePathTextBox.DataBindings.Add(new Binding("Tag", this.htmlModelBindingSource, "BasePath", true)); this.AddressTextBox.DataBindings.Add(new Binding("Text", this.htmlModelBindingSource, "ExtendPath", true)); this.AddressTextBox.DataBindings.Add(new Binding("Tag", this.htmlModelBindingSource, "ExtendPath", true)); this.fileXpath.DataBindings.Add(new Binding("Text", this.htmlModelBindingSource, "Match", true)); this.fileXpath.DataBindings.Add(new Binding("Tag", this.htmlModelBindingSource, "Match", true)); this.PropertyName.DataBindings.Add(new Binding("Text", this.htmlModelBindingSource, "AttrName", true)); this.PropertyName.DataBindings.Add(new Binding("Tag", this.htmlModelBindingSource, "AttrName", true)); }