Hi

It should be possible to manipulate bookmarks in Word from Powerbuilder. I
have a OLE object.

I get an error when I try to insert the text.
No problem getting the bookmarks but to insert data is impossible.
It doesn't recognise the function insert. I have seen an example of this
and it should funtion but it doesn't.

I run Powerbuilder 7.0.3 and Word 97.

LS_Cnt = ole_object.activedocument.Bookmarks.Count

ls_curr_bookmark = ole_object.activedocument.bookmarks.item(1).Name

FOR i = 1 TO LS_Cnt
ls_curr_bookmark = ole_object.activedocument.bookmarks.item(i).Name

CHOOSE CASE ls_curr_bookmark
CASE "test"
ole_object.activedocument.bookmarks.item).select
ole_object.Selection.Got(TRUE,0,0,ls_curr_bookmark)
ole_object.insert("text")
CASE "test2"
ole_object.insert(ls_last_name)
END CHOOSE
NEXT