Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / November 2006

Tip: Looking for answers? Try searching our database.

commands to manipulate tables

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
John Smith - 02 Nov 2006 02:15 GMT
What are the commands to manipulate tables?

I have a table containing two columns. Column a contains words and
b sentences. I would like to look in column b for the words that
are in column a and change their color to red.

I think this is doable but have no clue how to do it. Any help?
Thanks.
Lüko Willms - 02 Nov 2006 07:20 GMT
Am Thu, 2 Nov 2006 01:15:57 UTC,  schrieb John Smith
<jsmith@company.com>  auf microsoft.public.word.vba.general :

> What are the commands to manipulate tables?

 A Table is a collection of various objects (Table is itself a member
of the Tables collection) which each have certain properties and
provide various methods to act on those objects.

 The ones which you need are the Rows, Columns, and Cells, which are
indexed by their number, e.g. Rows(25), Columns(2), or Cells(7,5). The
VBE (Visual Basic Editor) helps you find the properties and methods of
those objects, and the online help also gives some information.

> I have a table containing two columns. Column a contains words and
> b sentences. I would like to look in column b for the words that
> are in column a and change their color to red.

 Your friend is the Find-Object and its sister, the
Replacement-Object.

 It is not clear to me, if you want to look only for words in the
same row, or if you want to search in all cells of column 2 for the
word in e.g. cells(1,1). Depending on that, you would loop thru all
cells of column 1 and use the full column 2 as "Range", on which the
Find/Replacement work, or you would select for each cell in column 1
the cell of column 2 in the same row, and chase the Find/Replacement
objects on that cell.

Hope that helps,
L.W.

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.