Hi @Rahul Kumar , Welcome to Microsoft Q&A,
You need to modify the access modifiers of label and textbox in itemedit.designer.cs to public;
public System.Windows.Forms.Label label1;
public System.Windows.Forms.TextBox textBox1;
In addition, there seems to be something wrong with this code:
if (edit.ShowDialog() == DialogResult.Yes)
{
error--> this.Rows[rowIndex].Cells[columnIndex].Value = edit.textBox1;
}
What effect do you want to achieve?
Best Regards,
Jiale
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.