private void toolStripMenuItemDouble_Click(object sender, EventArgs e) { ds_docstate.docstateRow docstateRow = AtGrid.getDataRow((Control)this.gridControlDocState) as ds_docstate.docstateRow; if (docstateRow == null) { return; } ds_docstate.docstateRow row = DocStateClass.dsDocState.docstate.NewdocstateRow(); row.iddocstate = dbconn.GetGenId("gen_docstate"); AtDataSet.LoadRow((DataRow)docstateRow, (DataRow)row, false); DocStateClass.dsDocState.docstate.AdddocstateRow(row); }
private void toolStripMenuItemPollDouble_Click(object sender, EventArgs e) { this.SaveToBase(); if (AtGrid.getSelectedDataRows((Control)this.gridControlPoll) == null) { return; } foreach (DataRow Source in AtGrid.getSelectedDataRows((Control)this.gridControlPoll)) { DataRow dataRow = this.ds_poll.Tables["poll"].NewRow(); dataRow["idpoll"] = (object)dbconn.GetGenId("gen_poll"); AtDataSet.LoadRow(Source, dataRow, false); this.ds_poll.Tables["poll"].Rows.Add(dataRow); } }