I am working on a windows form application using c#. I am using the grdiview smart tag in visual studio 2010 to populate data from a SQL data table in to the gridview. when i add new data to the table using SQL insert, the data in the gridview remains same unless i close the application. I want to code a REFRESH button, clicking which should populate the gridview again and then it will fetch all the data including the newly inserted.
How can I achieve this?
I am working on a windows form application using c#. I am using the
Share
If you used the assistant to connect to a database, it will generate code similar to this:
You can use the same line to update the database, like this: