BuilderSpec
Programmer
Hi all
Tricky problem for me hoping for an expert out there.
Got a C++ Builder program using the WordApplication object.
Have got some working code to find and go to a bookmark in a Word Document. this code is :
bmk2 = WordApplication.Exec(Procedure("EditBookmark")<< "ABC123" << 1 << 0 << 1 << 0 );
This is the equivalent of the VBA code
ActiveDocument.GoTo wdGoToBookmark, , , "test"
HOWEVER...
This code does not find bookmarks that are embedded. For example you can add a text box to a document and add a bookmark inside the text box. The existing VBA code will only find the bookmark if the text box is highlighted.
In VBA you get round this by using the different method of bookmark selection :
ActiveDocument.Bookmarks("test").Select
This will find a bookmark anywhere.. fantastic !
My question is : does anyone know the equivalent C++ Builder code to do the above ?
Regards
BuilderSpec
Tricky problem for me hoping for an expert out there.
Got a C++ Builder program using the WordApplication object.
Have got some working code to find and go to a bookmark in a Word Document. this code is :
bmk2 = WordApplication.Exec(Procedure("EditBookmark")<< "ABC123" << 1 << 0 << 1 << 0 );
This is the equivalent of the VBA code
ActiveDocument.GoTo wdGoToBookmark, , , "test"
HOWEVER...
This code does not find bookmarks that are embedded. For example you can add a text box to a document and add a bookmark inside the text box. The existing VBA code will only find the bookmark if the text box is highlighted.
In VBA you get round this by using the different method of bookmark selection :
ActiveDocument.Bookmarks("test").Select
This will find a bookmark anywhere.. fantastic !
My question is : does anyone know the equivalent C++ Builder code to do the above ?
Regards
BuilderSpec