Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Compare a Worksheet to another Worksheet.

Hello, any help would be appreciated.

I have two spread sheets, the data elements should be the same. So we must
verify this. Is there a way to compare a spread sheet to another spread
sheet to see the differences?

-- Thanks Susan
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,090
Default Compare a Worksheet to another Worksheet.

Susan
This little macro will do that. I assumed your two sheets were named
"One" and "Two", and the range to be checked is A1:P100. Change all that as
needed.
As written, this macro will compare each cell in sheet "One" with the same
cell in sheet "Two", and will color the cell in sheet "One" red if the
values are not the same. Post back if you need more. HTH Otto
Sub CompareSheets()
Dim Rng1 As Range
Dim i As Range
Sheets("One").Select
Set Rng1 = Range("A1:P100")
With Sheets("Two")
For Each i In Rng1
If i.Value < .Range(i.Address).Value Then _
i.Interior.ColorIndex = 3
Next i
End With
End Sub
"Susan@seaboard" wrote in message
...
Hello, any help would be appreciated.

I have two spread sheets, the data elements should be the same. So we
must
verify this. Is there a way to compare a spread sheet to another spread
sheet to see the differences?

-- Thanks Susan



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,290
Default Compare a Worksheet to another Worksheet.


If you don't want to do the programming... the commercial Excel add-in
"XL Companion" (from yours truly) can make several different types of
worksheet comparisons. See...
http://www.realezsites.com/bus/primitivesoftware
--
Jim Cone
San Francisco, USA
(Excel Add-ins / Excel Programming)


"Susan@seaboard"
wrote in message
Hello, any help would be appreciated.
I have two spread sheets, the data elements should be the same. So we must
verify this. Is there a way to compare a spread sheet to another spread
sheet to see the differences?
-- Thanks Susan
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 32
Default Compare a Worksheet to another Worksheet.


Otto, I got usae from your macro
However the 2 files i am comparing have their data arranged to different
collums
For example File A its colum 1 starts at row 2 whereas this colum infile B
is moved to colum 5 and starts at row 3. Is there a way since this relation
is always the same to define those relations as an offset and continue to use
your macro?

Ο χρήστης "Otto Moehrbach" *γγραψε:

Susan
This little macro will do that. I assumed your two sheets were named
"One" and "Two", and the range to be checked is A1:P100. Change all that as
needed.
As written, this macro will compare each cell in sheet "One" with the same
cell in sheet "Two", and will color the cell in sheet "One" red if the
values are not the same. Post back if you need more. HTH Otto
Sub CompareSheets()
Dim Rng1 As Range
Dim i As Range
Sheets("One").Select
Set Rng1 = Range("A1:P100")
With Sheets("Two")
For Each i In Rng1
If i.Value < .Range(i.Address).Value Then _
i.Interior.ColorIndex = 3
Next i
End With
End Sub
"Susan@seaboard" wrote in message
...
Hello, any help would be appreciated.

I have two spread sheets, the data elements should be the same. So we
must
verify this. Is there a way to compare a spread sheet to another spread
sheet to see the differences?

-- Thanks Susan




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 a value and if is true copy the line to other worksheet Florian Excel Worksheet Functions 2 July 31st 07 09:36 PM
How to compare two numeric column in same worksheet homefunwork.com Excel Worksheet Functions 5 February 2nd 07 04:17 PM
compare two columns within a worksheet, then highlight duplicates Beth Excel Worksheet Functions 1 September 20th 06 03:47 PM
I need to compare two worksheets and create a new worksheet Rajeev Ganesh Excel Discussion (Misc queries) 0 August 3rd 06 02:16 AM
How do I Compare worksheet columns dannix54 Excel Worksheet Functions 8 May 9th 05 02:26 AM


All times are GMT +1. The time now is 11:53 AM.

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"