View Single Post
 
Old 03-18-2019, 05:47 AM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 3,991
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

Plenty of ideas but confident in your ability to adapt the code already provided. We don't help out on forums like this just to do your work - we expect that you at least attempt to use the things you learn.

Have a close look at the code provided and see if you can work out what each line is doing. There is an if statement that could be expanded to have an alternative when the first test is false
If something below then
move it down
ElseIf something above then
move it up
end if

If you were to modify the code, you would need to define a second range towards the top of the doc and test for the string up there.

Make an attempt at creating a second range and use an ElseIf to search that one. If you can't work it out, post a sample of where you got to and we can provide some assistance.
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote