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 / Excel / New Users / July 2006

Tip: Looking for answers? Try searching our database.

compare 2 lists and common ones display on the 3rd column

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
elaine - 05 Jul 2006 18:26 GMT
Hi,

Is there a way to compare data in 2 columns, and display the same ones
that occur in both lists to a 3rd column?

Thanks.
Elaine.
somethinglikeant - 05 Jul 2006 18:38 GMT
Use a macro:-

Sub CompareAndPutinColumn3()
j = 1
For i = 1 To Application.WorksheetFunction.CountA(Columns(1))
   If Application.WorksheetFunction.CountIf(Columns(2), Cells(i, 1)) >
0 Then
       Cells(j, 3) = Cells(i, 1)
   j = j + 1
   End If
Next i
End Sub

somethinglikeant

> Hi,
>
[quoted text clipped - 3 lines]
> Thanks.
> Elaine.
elaine - 11 Jul 2006 15:48 GMT
thanks!!!

> Use a macro:-
>
[quoted text clipped - 18 lines]
> > Thanks.
> > Elaine.
elaine - 11 Jul 2006 15:48 GMT
thanks!!!

> Use a macro:-
>
[quoted text clipped - 18 lines]
> > Thanks.
> > Elaine.

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.