error occured when i insert data into excel 2007 using C# ?

i create one C# window application , in that application i have insert data into excel from aspx page ,but when i try to insert data i got the following error in my connectionstring

The 'Microsoft.ACE.OLEDB.12.0' provider is not registered on the local machine.

what can i do to solve this error ??
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

is the driver definitely installed? I can't remember if its installed by default or an optional install. Do you still have your office cd handy?
Parth48Author Commented:
My connectionstring is listed below ...

    <add key ="ExcelConnectionString" value="Provider=Microsoft.ACE.OLEDB.12.0;Data Source=E:\\Inventory.xlsx;Extended Properties=\Excel 12.0;HDR=Yes;IMEX=2\"/>

anything wrong in the above connectionstring or problem in other coding ..
please find the attachment of class file (General.cs)
Another thing, what platform are you running this on. Is it 64bit? Looks like driver might not be available
Have a read here for that plus a little more like the data connectivity components
OWASP Proactive Controls

Learn the most important control and control categories that every architect and developer should include in their projects.

Parth48Author Commented:
yes i used Window 7 Home Edition (64 bit) , where i can download the data connectivity drivers for 64 bit ?
Parth48Author Commented:
yes i have the office 2007 CD ...
what can i do next ?
Everything I read is 64bit drivers are not available yet. So you might find an issue here. Perhaps ask/check with microsoft.
MS Feedback link

A suggestion here is create via 32bit com interop

had similar problem and used following steps to solve it.

Basically, if you're on a 64-bit machine, IIS 7 is not (by default) serving 32-bit apps, which the database engine operates on. So here is exactly what you do:

1) ensure that the 2007 database engine is installed, this can be downloaded at:

2) open IIS7 manager, and open the Application Pools area. On the right sidebar, you will see an option that says "Set application pool defaults". Click it, and a window will pop up with the options.

3) the second field down, which says 'Enable 32-bit applications' is probably set to FALSE by default. Simply click where it says 'false' to change it to 'true'.

4) Restart your app pool (you can do this by hitting RECYCLE instead of STOP then START, which will also work).

5) done, and your error message will go away.

do not forget to give me points.
shubham, is jet compatable with office 2007? I didn't think it was.

So viral, if I wanted to develop a winform app, not using IIS, how does one solve this problem?
rockiroadsCommented: gives a list of connections for ado/excel.

I do not think you can use Jet as shubham has suggested but your welcome to give it a try.

Now these guys state that nothing is available for x64

but then when you do look at the details for 64bit it states office 2010 has 64bit drivers

With the new Office 2010, there will be new drivers coming, "2010 Office System Driver", which will be provided as both 32-bit and 64-bit versions. You can use these drivers to let you application connect to Access, Excel and text-files in a 64 bit environment, utilizing the new 64 bit drivers. The provider name is "Microsoft.ACE.OLEDB.14.0". You don't need to buy or install the Office suite, the components are available as a separate download.

So maybe you can give this a try and see how well that works for you. Your current connection string uses OLEDB 12.0 which is office 2007. You will probably have to change this to OLEDB 14.0.

Let us know if this works for you.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
I take it back about the provider string. The MS article states this

2.If you are an application developer using OLEDB, set the Provider argument of the ConnectionString property to “Microsoft.ACE.OLEDB.12.0”
¿If you are connecting to Microsoft Office Excel data, add “Excel 14.0” to the Extended Properties of the OLEDB connection string.
Parth48Author Commented:
thanks to all of you for support ...
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.