Posted on: 3/12/2011 12:10:19 AM | Views : 228

i am facing the error
The Microsoft Jet database engine could not find the object 'MyDataFile$'.  Make sure the object exists and that you spell its name and the path name correctly.
below is my code,  i am exporting my excel sheet in HTML format. in case of importing i am facing the above mentioned error.

How can i resolve this problem.
 
DataTable dt = new DataTable();
        string Excel = Server.MapPath("App_Data/MyDataFile.xls");
        string connect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + Excel + ";Extended Properties=HTML Import;";
        using (OleDbConnection conn = new OleDbConnection(connect))
        {

            using (Ol ...

Go to the complete details ...