Search code examples
javaexceloleole-automation

Is there OLE Automation in Java?


Is it possible to use OLE Automation in Java? If not, why is it not possible in Java?

I'm looking to automate the exporting of excel spreadsheets in different format (ie, .csv etc...)

Thanks for the answers in advance :)


Solution

  • You can use JACOB. But there will be some pain involved as it's not documented very well and the performance is not the best. It can also be hard to get it running correctly for you environment depending on which version of Windows you are targetting. I would definitely not use it if you are building a scalable web application. Another option would be Apache POI which has really come a long way from its early roots and is used in alot of production ready tools like JBoss Drools. If you decide to go with JACOB then I recommend you read this SO thread:

    Is there a good reference for using OLE Automation (from Java)?