hello all
I am using .Net C# & MySql i made a data entry form to fill the tables and it's working ok. my data entry form consists of textboxes through each one I will save the data to the tables. the problem began when I tried to display the info. in my tables using the textbox, I want to be able not just to enter data but also walk through my table using a next and prev. buttons . here is my code
the table contains 10 records but the button only work for one click
thank you all for your concern
I am using .Net C# & MySql i made a data entry form to fill the tables and it's working ok. my data entry form consists of textboxes through each one I will save the data to the tables. the problem began when I tried to display the info. in my tables using the textbox, I want to be able not just to enter data but also walk through my table using a next and prev. buttons . here is my code
Code:
private void next_Click(object sender, System.EventArgs e)
{
i+=1;
if (i <= ds.Tables[0].Rows.Count)
{
empid.Text = ds.Tables[0].Rows[i][0].ToString(); empnam.Text = ds.Tables[0].Rows[i][1].ToString();
empdesc.Text = ds.Tables[0].Rows[i][2].ToString();
i+=1;
}
thank you all for your concern
Comment