Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Visual J# / June 2004

Tip: Looking for answers? Try searching our database.

Java calling Office API ?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Oleg Konovalov - 02 Jun 2004 23:16 GMT
Hi,

I am writing a Java application which among many other things
has to call some MS Office [PowerPoint] internal methods,
which only seems to be possible from either VBA or C#.

Can anybody suggest a way of Java calling VBA or C# ?

I do know how to call an executable from Java
or Java interface with C/C++ through JNI.

Thank you in advance,
Oleg.

P.S.: If you know how to call PowerPoint from Java or VC++,
please speak out too.
Lars-Inge T?nnessen - 03 Jun 2004 14:30 GMT
> has to call some MS Office [PowerPoint] internal methods,
> which only seems to be possible from either VBA or C#.

The Office methods are methods in COM objects and can be called from any language that supports COM. As we all know, Sun is/was not
very fond of the COM support MS offered in their Java implementation, so Sun does not support it.

You can get this COM (bridge) support from an other third parts like http://www.intrinsyc.com/ for the Sun Java.

http://j-integra.intrinsyc.com/

With J-Integra the COM objects appears as normal Java objects.

There is a second bridge:
http://www.jnbridge.com/

However these brides have a serious price tag if this is for personal home enthusiast usage. I think they offer free trail versions.

> Can anybody suggest a way of Java calling VBA or C# ?

I have called .net from Java over RMI - SOAP - Remoring.net calls, using the free Axis Apache xml webservice api (wsdl)
http://ws.apache.org/axis/ . The downside is that this is veeeery slooooow, and it does only support a few primitives like int,
double, string etc, and you have to read and modify the generated java code.

> I do know how to call an executable from Java
> or Java interface with C/C++ through JNI.

A C++ call is probably what you should be looking more at.

A google search on "Automating MS-Office applications" gives us lots of hits. If you know C++ here is a power point  example :

http://www.codeproject.com/com/ole_automation.asp

Regards,
Lars-Inge T?nnessen
www.larsinge.com
Lars-Inge T?nnessen - 03 Jun 2004 15:02 GMT
I forgot to include this link:

http://jawinproject.sourceforge.net/

Regards,
Lars-Inge T?nnessen
www.larsinge.com
George Birbilis [MVP J#] [9880] - 17 Jun 2004 22:34 GMT
with J#, you can use the Microsoft Office COM interfaces (for free), since
.NET can call into COM. Don't need to use VS.net, can use the command line
compiler too

plus there is a special VS.net addon package for Office (what used to be the
Office Professional now is an add-on for Visual Studio.net if I've got it
well). That should have some extra useful docs among other things

> I am writing a Java application which among many other things
> has to call some MS Office [PowerPoint] internal methods,
[quoted text clipped - 10 lines]
> P.S.: If you know how to call PowerPoint from Java or VC++,
> please speak out too.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.