private void Form1_Load(object sender, EventArgs e)
{
DBWebService.DatabaseWS s = new DBWebService.DatabaseWS();
ds = s.Get_Price_List_Header();
this.dataGridView1.DataSou
rce = ds.Tables[0];
this.MainTabControl.TabPag
es.RemoveA
t(3);
}
private void dataGridView1_DoubleClick(
object sender, EventArgs e)
{
// Get last row
currRow = this.dataGridView1.Current
Row;
Get the row into a datatable or datarow? What ever corresponds to a row of a datagrid that will get all the values from the corresponding row in the dataset.
// Get the row count
int rowcount = this.dataGridView1.Binding
Context[th
is.dataGri
dView1.Dat
aSource].C
ount-1;
// Mode 1
//////////////////////////
//////////
//////////
////////
if ((dataGridView1.SelectedRo
ws[0].Cell
s[7].Value
!= null) && (rowcount >= this.dataGridView1.Current
Row.Index)
)
{
string s = dataGridView1.SelectedRows
[0].Cells[
7].Value.T
oString();
ModeType = modeEnum.mode1;
MessageBox.Show(s + " The Last Column was selected");
MessageBox.Show("Load the header draft row into page nad move the path name into input textbox. Remove file from output folder. Enable all buttons. Readonly for textboxes. Disable PoolYear and List No. Save and update price_list_hdr", "My Application",
MessageBoxButtons.OKCancel
, MessageBoxIcon.Asterisk);
}
//////////////////////////
//////////
//////////
//////
this.MainTabControl.Select
Tab(1);
}
Start Free Trial