Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Troubleshooting
Research
Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

Create bookmarks in the only table of the active document using VBA

Avatar of Andreas Hermle
Andreas HermleFlag for Germany asked on
Microsoft Word
8 Comments1 Solution484 ViewsLast Modified:
Dear Experts:

I got a 2 column table in the currently active document. The number of rows can vary from
1 to n rows depending on the currently active document.

I would like to run a macro that ...
... creates bookmarks of the cell values in the second column of the only table in the currently active document.
... The macro is to run thru the table from top to bottom. The bookmarks are to be named:

bookmark_01
bookmark_02
bookmark_03
bookmark_nn

Example sample table

Column 1    Column 2

17                Surgery Department
13                Oncology Department
18                Pediatrics Department

So the following bookmarks should be created

bookmark_01 = Range of Text marked by the bookmark: Surgery Department
bookmark_02 = Range of Text marked by the bookmark: Oncology Department
bookmark_03 = Range of Text marked by the bookmark: Pediatrics Department

The range of text marked by the bookmark is not to include the cell end marker

Help is much appreciated, thank you very much in advance.

Regards, Andreas
ASKER CERTIFIED SOLUTION
Avatar of Robert Schutt
Robert SchuttFlag of Netherlands imageSoftware Engineer

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Commented:
This problem has been solved!
Unlock 1 Answer and 8 Comments.
See Answers