Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Compare Worksheet Values


I have two worksheets sheet1 and sheet2. Each cells in
the worksheets are text values. Sheet1 range of cells is
(A1:A1677) and sheet2 range of cells is (A1:A822).

I would like to see if the values in sheet2 are listed in
sheet1. If the value is found in sheet1 then color that
cell background yellow. Compare each cell value in sheet2
against sheet1.

Please help me create a Excel VB macro to complete this
task.

Thank You,

Steven
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 422
Default Compare Worksheet Values

Name your Sheet1 range A1:A1677 "MySheet1Data".
In cell A1 of Sheet2, click on Format, Conditional Formatting and
then choose "Formula Is" and type in:

=COUNTIF(MySheet1Data,A1)0

then Format button, pattern yellow,,,,
OK, OK

then with format painter - click on A1 of Sheet2 and paint cells A2:A822
Your all set!!
HTH


"Steven" wrote in message
...

I have two worksheets sheet1 and sheet2. Each cells in
the worksheets are text values. Sheet1 range of cells is
(A1:A1677) and sheet2 range of cells is (A1:A822).

I would like to see if the values in sheet2 are listed in
sheet1. If the value is found in sheet1 then color that
cell background yellow. Compare each cell value in sheet2
against sheet1.

Please help me create a Excel VB macro to complete this
task.

Thank You,

Steven



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Compare values on sheet 1 to values on sheet2 Colin Excel Worksheet Functions 2 August 2nd 06 07:19 PM
Excel Compare values in columns & display missing values in a new cpetta Excel Discussion (Misc queries) 1 April 2nd 05 05:51 AM
Compare Listbox values with Collection values Stuart[_5_] Excel Programming 2 September 20th 03 01:58 PM
compare values between workbooks and copy values bgardiner Excel Programming 0 September 9th 03 03:54 PM


All times are GMT +1. The time now is 02:02 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"