thanks viper.
On Wed, Dec 28, 2011 at 12:34 PM, The Viper <viper....@gmail.com> wrote: > see the attachment if you want to do it with combination of functions > > > > On Wed, Dec 28, 2011 at 11:57 AM, Aamir Shahzad > <aamirshahza...@gmail.com>wrote: > >> thanks for your response Dguillett1 & Rohan but when I run the macro its >> shows attached error. Please see the issue. And I don't want to remove the >> duplicates if names repeat it should show the same codes of same name. >> >> Regards, >> >> Aamir Shahzad >> >> On Wed, Dec 28, 2011 at 10:01 AM, Maries <talk2mar...@gmail.com> wrote: >> >>> *Remove Duplicates:* >>> Sub Macro1() >>> ' >>> ' Macro1 Macro >>> ' >>> ' >>> Range("C1:D26").Select >>> ActiveSheet.Range("$C$1:$D$26").RemoveDuplicates Columns:=Array(1, >>> 2), Header:=xlYes >>> End Sub >>> Regards, >>> >>> MARIES. >>> On Tue, Dec 27, 2011 at 11:50 PM, Rohan <bittu.ro...@gmail.com> wrote: >>> >>>> One more way of doing it... >>>> >>>> Sub Macro1() >>>> >>>> Range("A1:B" & Cells(Rows.Count, "B").End(xlUp).Row).Select >>>> Application.CutCopyMode = False >>>> Range("A1:B" & Cells(Rows.Count, >>>> "B").End(xlUp).Row).AdvancedFilter Action:=xlFilterCopy, >>>> CopyToRange:=Range( _ >>>> "F1"), Unique:=True >>>> Columns("G:G").EntireColumn.AutoFit >>>> >>>> End Sub >>>> >>>> >>>> Regards, >>>> Rohan. >>>> >>>> -- >>>> FORUM RULES (934+ members already BANNED for violation) >>>> >>>> 1) Use concise, accurate thread titles. Poor thread titles, like Please >>>> Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice >>>> will not get quick attention or may not be answered. >>>> >>>> 2) Don't post a question in the thread of another member. >>>> >>>> 3) Don't post questions regarding breaking or bypassing any security >>>> measure. >>>> >>>> 4) Acknowledge the responses you receive, good or bad. >>>> >>>> 5) Cross-promotion of, or links to, forums competitive to this forum >>>> in signatures are prohibited. >>>> >>>> NOTE : Don't ever post personal or confidential data in a workbook. >>>> Forum owners and members are not responsible for any loss. >>>> >>>> >>>> ------------------------------------------------------------------------------------------------------ >>>> To post to this group, send email to excel-macros@googlegroups.com >>>> >>> >>> -- >>> FORUM RULES (934+ members already BANNED for violation) >>> >>> 1) Use concise, accurate thread titles. Poor thread titles, like Please >>> Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice >>> will not get quick attention or may not be answered. >>> >>> 2) Don't post a question in the thread of another member. >>> >>> 3) Don't post questions regarding breaking or bypassing any security >>> measure. >>> >>> 4) Acknowledge the responses you receive, good or bad. >>> >>> 5) Cross-promotion of, or links to, forums competitive to this forum in >>> signatures are prohibited. >>> >>> NOTE : Don't ever post personal or confidential data in a workbook. >>> Forum owners and members are not responsible for any loss. >>> >>> >>> ------------------------------------------------------------------------------------------------------ >>> To post to this group, send email to excel-macros@googlegroups.com >>> >> >> >> >> -- >> >> Regards, >> >> Aamir Shahzad >> >> -- >> FORUM RULES (934+ members already BANNED for violation) >> >> 1) Use concise, accurate thread titles. Poor thread titles, like Please >> Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice >> will not get quick attention or may not be answered. >> >> 2) Don't post a question in the thread of another member. >> >> 3) Don't post questions regarding breaking or bypassing any security >> measure. >> >> 4) Acknowledge the responses you receive, good or bad. >> >> 5) Cross-promotion of, or links to, forums competitive to this forum in >> signatures are prohibited. >> >> NOTE : Don't ever post personal or confidential data in a workbook. Forum >> owners and members are not responsible for any loss. >> >> >> ------------------------------------------------------------------------------------------------------ >> To post to this group, send email to excel-macros@googlegroups.com >> > > > > -- > *Great day,* > *viper* > -- > FORUM RULES (934+ members already BANNED for violation) > > 1) Use concise, accurate thread titles. Poor thread titles, like Please > Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice > will not get quick attention or may not be answered. > > 2) Don't post a question in the thread of another member. > > 3) Don't post questions regarding breaking or bypassing any security > measure. > > 4) Acknowledge the responses you receive, good or bad. > > 5) Cross-promotion of, or links to, forums competitive to this forum in > signatures are prohibited. > > NOTE : Don't ever post personal or confidential data in a workbook. Forum > owners and members are not responsible for any loss. > > > ------------------------------------------------------------------------------------------------------ > To post to this group, send email to excel-macros@googlegroups.com > -- Regards, Aamir Shahzad -- FORUM RULES (934+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. ------------------------------------------------------------------------------------------------------ To post to this group, send email to excel-macros@googlegroups.com