LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Find cell (with duplicates)


Hi,

I have a worksheet(1) with a lot of data in column B. In this data
duplicates exist. I have another worksheet(2) (a copy of worksheet(1))
on which the user can add rows and data in column B. I have some code
(see below) to copy values from column P of worksheet(2) to column F of
worksheet(1).
The only problem is there are duplicates in column B of worksheet(1).
So by using the code below it allways gets the first duplicate and
that's not how it should go.
Can someone help me change the code so it will find the right
duplicate? Thanks in advance!


Code:
--------------------
For Each cell In Sheets("Begroting WVB Won").Range("B12:B242")
myvalue = cell.Offset(0, 14).Value
Set myCell = Worksheets("Totaaloverzicht Won").Range("B:B").Find _
(cell.Value)
myCell(1, 5).Value = myvalue
Next cell
--------------------


--
leonidas
------------------------------------------------------------------------
leonidas's Profile: http://www.excelforum.com/member.php...o&userid=35375
View this thread: http://www.excelforum.com/showthread...hreadid=568885

 
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
Find Duplicates rap43 Excel Discussion (Misc queries) 4 October 22nd 09 05:01 PM
Find Duplicates Vic Excel Discussion (Misc queries) 9 August 17th 09 08:36 PM
find duplicates Dylan @ UAFC[_2_] Excel Worksheet Functions 5 December 14th 08 03:00 PM
Find duplicates R. Choate Excel Discussion (Misc queries) 5 November 28th 04 10:14 PM
Find duplicates ljCharlie[_5_] Excel Programming 7 May 11th 04 12:56 PM


All times are GMT +1. The time now is 07:13 AM.

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

About Us

"It's about Microsoft Excel"