Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 536
Default Copy & Paste Conditional Formatted duplicates w/vba

Excel 2010

I have a large list of names/words with a X - O binary code next to each name/word. The columns with the XO codes is conditional formatted to show duplicates. In this example 1 & 2 are CF highlighted as the O's are accounting for the letter N in both names and just happen to be the same X-O code. In 3 and 4 the O's are accounting for the letter D in both names but are not duplicates codes. (Somewhere else in the list the O is accounting for the O's in both names and they also are not duplicates codes.)


1. XXXO XXXXXO JOHN DRYDEN
2. XXXO XXXXXO JOAN DIDION

3. XXXX OXXOXX JOHN DRYDEN
4. XXXX OXOXXX JOAN DIDION

Is there some method using VBA to go through a column and identify the JOHN and JOAN duplicate codes and then copy & paste one of them (code & name) to a fresh column. There could be several "JOHN-JOAN" like duplicates in the column.

Something like:

Dim i As Interger
Dim JohnCode As String
Dim JoanCode As String
Dim c As Range
Dim Coder As Range

With Selection
For Each c in Range("Coder")
If JohnCode = JoanCode then
JohnCode.c Resize(1,2).Copy Range("B100").End(xlup).Offset(1,0)
End If
Next
End With

I've looked through HELP and fooled around with the FIND-REPLACE feature but CF seems to be immune to 'normal' look-see-copy-paste.

Thanks.
Regards,
Howard




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
How can I copy the formatted value and paste as a new value(not the original value with formatting)? Daniel Excel Discussion (Misc queries) 2 May 7th 23 11:42 AM
Copy current color of conditional formatted cell justme Excel Programming 4 October 18th 07 01:17 PM
Conditional Copy/Paste Dan R. Excel Programming 5 February 21st 07 09:31 PM
Excel 2007: copy/paste formatted cells? putty Excel Discussion (Misc queries) 2 June 14th 06 09:12 PM
Copy multiple entries and paste without duplicates ExcelMonkey[_116_] Excel Programming 2 May 13th 04 09:45 PM


All times are GMT +1. The time now is 10:50 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"