jthomas666
Technical User
This will be a macro for Word 07. I've got some code that extracts info from Access and puts it into a table in word:
Row-----heading------text
1----------A-----------------yada yada
2----------A-----------------whatever
3----------A-----------------yawn
4----------B------------------hello
5----------C-----------------goodbye
6----------C-----------------get on with it
etc.
What I would like is a macro that will start in row 1, and compare the heading value with the heading value in row B. If they are identical, delete the row 2 value, and proceed to row three. If the values differ, then take the row two value and compare it to row three, etc.
So that the finished result would be
1----------A-----------------yada yada
2-----------------------------whatever
3-----------------------------yawn
4----------B------------------hello
5----------C-----------------goodbye
6-----------------------------get on with it
etc.
I have a bookmark set in the first row, and I already have the number of rows stored as a variable. It'll be an if-then nested in a For loop, but that's about the extent of my VBA skills.
thanks,
Row-----heading------text
1----------A-----------------yada yada
2----------A-----------------whatever
3----------A-----------------yawn
4----------B------------------hello
5----------C-----------------goodbye
6----------C-----------------get on with it
etc.
What I would like is a macro that will start in row 1, and compare the heading value with the heading value in row B. If they are identical, delete the row 2 value, and proceed to row three. If the values differ, then take the row two value and compare it to row three, etc.
So that the finished result would be
1----------A-----------------yada yada
2-----------------------------whatever
3-----------------------------yawn
4----------B------------------hello
5----------C-----------------goodbye
6-----------------------------get on with it
etc.
I have a bookmark set in the first row, and I already have the number of rows stored as a variable. It'll be an if-then nested in a For loop, but that's about the extent of my VBA skills.
thanks,