Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-28-2014, 08:05 AM
smakdown61 smakdown61 is offline Find and Replace multiple table columns Windows 7 32bit Find and Replace multiple table columns Office 2010 32bit
Novice
Find and Replace multiple table columns
 
Join Date: Aug 2014
Posts: 1
smakdown61 is on a distinguished road
Default Find and Replace multiple table columns

I have a large table in Word where I would like to do a Find and Replace based on multiple columns. Example:



If Column A = "IO", then replace Column C with "YES".

Is this possible? Or would it be easier just to copy it into excel, make the change, and copy back?
Reply With Quote
  #2  
Old 08-28-2014, 09:24 PM
gmayor's Avatar
gmayor gmayor is offline Find and Replace multiple table columns Windows 7 64bit Find and Replace multiple table columns Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,101
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

You can do it in Word easily enough. Assuming IO is the content if the cell and not part of the content then the following macro will work

Code:
Sub GetIO()
Dim oRow As Row
Dim oCell As Range
    For Each oRow In Selection.Tables(1).Rows
        Set oCell = oRow.Cells(1).Range
        oCell.End = oCell.End - 1
        If oCell.Text = "IO" Then oRow.Cells(3).Range.Text = "YES"
    Next oRow
End Sub
http://www.gmayor.com/installing_macro.htm
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro for find/replace (including headers and footers) for multiple documents jpb103 Word VBA 2 05-16-2014 04:59 AM
Find and Replace multiple table columns How do I find/replace the same word in multiple documents? Ineedhelp! Word 3 03-04-2014 03:50 PM
Find and Replace multiple table columns How do I find and replace multiple items at once? redzan Word VBA 1 05-16-2013 08:25 AM
Find and Replace multiple table columns Find and Replace multiple lines/paragraphs jcw Word 1 11-18-2011 11:47 AM
Find and replace multiple documents change style BaPW Word 0 08-14-2011 11:12 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:06 AM.


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