Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Deleting Duplicate Rows

I've not had success using the macros listed to delete
rows where the first cell is the same. For example,

* Sheet1 has name in column 1 (shorter file)
* Sheet2 has name in column 1 and address in column 2
(longer file)

I want Sheet1 to drive the selection of rows in Sheet2,
resulting in a name and address subset file of Sheet2.

Thank you,
Connie


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Deleting Duplicate Rows

in sheet2 put a formula in column 3

=if(countif(Sheet1!A:A,A1)0,"Keep","Delete")

You can copy this down the column, then use the Autofilter to extract the
rows you want.

Use the same approach in a macro.

--
Regards,
Tom Ogilvy

Connie wrote in message
...
I've not had success using the macros listed to delete
rows where the first cell is the same. For example,

* Sheet1 has name in column 1 (shorter file)
* Sheet2 has name in column 1 and address in column 2
(longer file)

I want Sheet1 to drive the selection of rows in Sheet2,
resulting in a name and address subset file of Sheet2.

Thank you,
Connie




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Deleting Duplicate Rows

Tried your suggestion but it only worked by placing a Keep
in the first row of sheet 2....all other rows said
delete....thanks!

-----Original Message-----
in sheet2 put a formula in column 3

=if(countif(Sheet1!A:A,A1)0,"Keep","Delete")

You can copy this down the column, then use the

Autofilter to extract the
rows you want.

Use the same approach in a macro.

--
Regards,
Tom Ogilvy

Connie wrote in

message
...
I've not had success using the macros listed to delete
rows where the first cell is the same. For example,

* Sheet1 has name in column 1 (shorter file)
* Sheet2 has name in column 1 and address in column 2
(longer file)

I want Sheet1 to drive the selection of rows in Sheet2,
resulting in a name and address subset file of Sheet2.

Thank you,
Connie




.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Deleting Duplicate Rows

It works fine for me and should work for you. I suspect your problem lies
with your data not matching. Possibly you have blanks spaces on the end of
your data in one sheet or the other.

--
Regards,
Tom Ogilvy

Connie wrote in message
...
Tried your suggestion but it only worked by placing a Keep
in the first row of sheet 2....all other rows said
delete....thanks!

-----Original Message-----
in sheet2 put a formula in column 3

=if(countif(Sheet1!A:A,A1)0,"Keep","Delete")

You can copy this down the column, then use the

Autofilter to extract the
rows you want.

Use the same approach in a macro.

--
Regards,
Tom Ogilvy

Connie wrote in

message
...
I've not had success using the macros listed to delete
rows where the first cell is the same. For example,

* Sheet1 has name in column 1 (shorter file)
* Sheet2 has name in column 1 and address in column 2
(longer file)

I want Sheet1 to drive the selection of rows in Sheet2,
resulting in a name and address subset file of Sheet2.

Thank you,
Connie




.



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
Deleting duplicate rows Ranju Excel Discussion (Misc queries) 1 January 28th 09 12:14 PM
Find duplicate rows then deleting them SSHO_99 Excel Worksheet Functions 4 May 4th 07 11:17 AM
deleting duplicate rows Jess Excel Discussion (Misc queries) 3 January 9th 07 11:16 PM
Deleting duplicate rows Kevin Excel Discussion (Misc queries) 1 May 2nd 06 12:16 AM
Deleting Duplicate Rows pettes01 Excel Discussion (Misc queries) 4 November 8th 05 06:50 PM


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