1

How to add text to a C# datagrid from a textbox using a button click

1
  • hey look at this there's something called google and MSDN Commented Mar 18, 2009 at 12:18

2 Answers 2

1

in the button's click event handler, add a row (assuming you want to add a row) to the datagrid with the contents from the textbox.

Sign up to request clarification or add additional context in comments.

Comments

0

You need to give more information. Do you have a DataTable bound to the DataGrid already? Have you created columns in the DataTable? Are you sure it's not actually a DataGridView (the .net 2.0 + version of DataGrid)? Is it ASP or Winforms?

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.