You can use dataset.GetXml method to get the xml private const string xcel_CONN_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source={0};Extended Properties=Excel 8.0;"; internal DataSet GetExcelDataToDataSet(string filepath, string sheetname) { OleDbConnection cn = null; OleDbDataAdapter da = null; DataSet ds = null; try { cn = new OleDbConnection(string.Format(xcel_CONN_STRING, filepath)); cn.Open(); da = new OleDbDataAdapter(string.Format(xcel_sql, sheetname), cn); ds = new DataSet(); da.Fill(ds); return ds; } catch (Exception ex) { throw new Exception(ex.Message); } finally { if(cn != null) { cn.Close(); cn.Dispose(); } } }