-1

I have searched on google but I can not find a solution for this. So I ask the StackOverflow community.

I want to use the SDK for OpenOffice (Java) to replace the text content in an OpenOffice Writer document.

How can I do that? The examples on the google search are helpless.

sm_a
  • 11
  • 4

2 Answers2

0

You load the document, create a textcursor, navigate to the text to be replaced, select it, replace it with new text and save the document.

What have you tried so far?

You do know MRI extension, which can record the steps and produce code?

ngulam
  • 995
  • 1
  • 6
  • 11
-1

How about the examples directly from Open Office for the sdk:

Open Office SDK examples

The one under "Writer" called "TextReplace" should be precisely what you are looking for.

Paul Jowett
  • 6,513
  • 2
  • 24
  • 19