Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 09-13-2012, 10:35 AM
jperez84 jperez84 is offline Macro that can find phrase and then find another and copy Windows XP Macro that can find phrase and then find another and copy Office 2007
Novice
Macro that can find phrase and then find another and copy
 
Join Date: Sep 2012
Posts: 21
jperez84 is on a distinguished road
Default Macro that can find phrase and then find another and copy

Good afternoon,

The macro I'm trying to setup should first find a certain phrase (there will be many different ones and would like to put them all in at once), let’s say “hello there buddy”. From there it will search for another set of characters above it. Let’s say “NAM/” and it will copy that entire line (if there is a way to tell it only to copy between the first set on “//” or the second, etc is even better) . The only thing is that it’s never the same amount of characters above or lines above. From there it will copy the text into an excel spreadsheet. Also, is it possible for the macro to find "NAM/" and lets say "test" and copy both lines and put them next to each other in two separate cells? Or should a second macro be rum and just change the parameters? Below is an example of how the word doc is setup. Setup is similar to another question I posted a few days ago, but the output s different.

Thanks in advance.

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
test1 NAM/smith, peter/ jackson, Samantha/
123
test
unneeded info


hello there buddy

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
test2 NAM/jones,Jeffrey/ sandler,adam/
356
another
test
can you
believe it
I can’t
hello there buddy
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro that can find phrase and then find another and copy Find, copy and paste into a new page jperez84 Word VBA 24 09-20-2012 11:34 AM
Trying to find and copy all headings at the same time WaltR Word 7 08-21-2012 03:12 PM
Macro that can find phrase and then find another and copy How to find exact phrase CabbageTree Outlook 2 05-14-2012 11:24 AM
Macro that can find phrase and then find another and copy Bad view when using Find and Find & Replace - Word places found string on top line paulkaye Word 4 12-06-2011 11:05 PM
Find and Replace Macro - A Better Way Tribos Word VBA 0 10-08-2008 03:22 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:08 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft