2
Reply

Populate a datagrid view using SQL C#

Daniel

Daniel

Mar 7 2011 5:08 PM
6.3k
Hi,

I have a database with a few tables in, one being "Customers"

I don't know how to fill the datagrid with the Customers table contents
I need to be able to display that table in a datagrid view on the click of a button on my customers search form

I will eventually be able to search by name, post code, city and ALL which is what i need to do first

I think I have tp use data adapters and data sets but I'm not exactly sure how to use them with SQL to get the results I want

I am using SQL Server 2005, Visual Studio 2008 and C#

Any help would be appreciated

Thanks


Answers (2)