tags:

views:

32

answers:

2

I would like to call a word macro from a java program and pass the macro a search string. Is there anyway to do this?

A: 

Use Com4J to generate the access classes for Word. Now call your macro as you would from VBA.

Daniel
A: 

What is your broader objective? I mean, what is the purpose of the macro?

jowierun
Macro pulls out sections of text based on heading styles, you pass in a string which the macro matches to heading styles and retrieves that block of text
Holograham