Hi
How to import data from Microsoft Excel 2010 to Gridview
am using web application.(visual studio 2010)
String strConn = "Provider=Microsoft.Jet.OLEDB.4.0;" + "Data Source=D:\\Book1.xls;" + "Extended Properties=Excel 8.0;HDR=NO;";
DataTable ds = new DataTable();
string strSQL = "SELECT * FROM [Sheet1$]";
OleDbDataAdapter da = new OleDbDataAdapter(strSQL, strConn);
da.Fill(ds);
grvPatient.DataSource = ds;
grvPatient.DataBind();
m trying like this it provide error