MrExcel Message Board

Go Back   MrExcel Message Board > Question Forums > Excel Questions

Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only.

Reply
 
Thread Tools Display Modes
Old May 16th, 2002, 01:28 PM   #1
amna77
Board Regular
 
Join Date: May 2002
Posts: 251
Default

Hi,
Can any body help me with this.
I want a create a macro.
If I have a duplicate Value in column A then delete that entire row. and serach for the next duplicate value.

Any idea?????????

Thanks in Advance

amna77 is offline   Reply With Quote
Old May 16th, 2002, 02:10 PM   #2
teebruin
New Member
 
Join Date: Mar 2002
Posts: 38
Default

Do a search of the message board, and you should get a lot of hits. This topic has been covered numerous times.
teebruin is offline   Reply With Quote
Old May 16th, 2002, 03:16 PM   #3
brettvba
MrExcel MVP
 
Join Date: Feb 2002
Location: Christchurch New Zealand
Posts: 1,030
Default

try this made earlier in posts

Sub NoDups()
Application.ScreenUpdating = False
Dim RowCntr As Long, FromRowCntr As Long, LastRow As Long
Dim CompareStr
Dim FirstString As String, SecondString As String
On Error Resume Next
LastRow = Range("a2:a" & Range("a65536").End(xlUp).Row).Rows.Count
For RowCntr = 2 To LastRow
FirstString = Range("a" & RowCntr) ' & Range("a" & RowCntr)
If Len(Trim(FirstString)) = 0 Then Exit Sub
For FromRowCntr = RowCntr + 1 To LastRow
SecondString = Range("a" & FromRowCntr) '& Range("a" & FromRowCntr)
CompareStr = StrComp(FirstString, SecondString, 1)
If CompareStr = 0 Then
Rows(FromRowCntr & ":" & FromRowCntr).Delete Shift:=xlUp
FromRowCntr = FromRowCntr - 1
LastRow = LastRow - 1
End If
Next
Next
End Sub

_________________


EDIT This Works for row A only

[ This Message was edited by: brettvba on 2002-05-16 14:38 ]
brettvba is offline   Reply With Quote
Old May 16th, 2002, 03:20 PM   #4
xl
New Member
 
Join Date: May 2002
Posts: 10
Default

It's so annoying when lazy people expect everyone else to do the work for them.
xl is offline   Reply With Quote
Old May 16th, 2002, 03:35 PM   #5
Jack in the UK
Board Regular
 
Join Date: Feb 2002
Posts: 3,065
Default


XL

Hi its Jack = you seem to be a little harsh in you post and you have insulted more than one poster so far in what I have read in 10 minutes, what’s up mate something bugging you.

This board is for everyone world wide regardless NO BARRIERS, so if the guy posting is a little less in competence than you FINE help him out that’s why the board is here so all levels can get help from the hardest question to the smallest silly question..

IF you are a guru let me know I have many issues that I can not solve maybe you will assist me and others in some work and we will only ever thank you for this.

Please be polite… it just a respect to each other..

If I did not care why would I bother ive written two long passages to you, come on join in the fun.

Also if you have issues please email me or PM me ill chat what ever you like over.

Jackintheuk@hotmail.com



__________________
Free Excel based Web Toolbar available here.

Jack in the UK
J & R Excel Solutions
"making Excel work for you"
Jack in the UK is offline   Reply With Quote
Old May 16th, 2002, 09:58 PM   #6
Nimrod
MrExcel MVP
 
Join Date: Apr 2002
Location: Vancouver BC , Canada
Posts: 6,259
Default

Jack:
With every post of yours,that I read, I gain respect for you. This guy Dis'd you and you have the "class" to respond with tact and Courtesy. My hat is off to you ! I agree with everything you said... Thanks for attempting to keep this board from degenerating into disrespectful chatter.
Nimrod is offline   Reply With Quote
Old May 17th, 2002, 09:42 AM   #7
MrExcel
.
 
MrExcel's Avatar
 
Join Date: Feb 2002
Location: Akron, Ohio USA
Posts: 789
Default

It is interesting to me that XL is posting from an I.P. "inside" of Microsoft.

I've never actually tried to get support from Microsoft, but I wonder if this is an indication of their usual demeanor?


__________________
Preview my latest book for Free
MrExcel is offline   Reply With Quote
Old May 17th, 2002, 01:58 PM   #8
Jack in the UK
Board Regular
 
Join Date: Feb 2002
Posts: 3,065
Default

Hi its Jack

I live in a tough area of South London and enjoy the mix of life and culture, and the democratic society our county the UK believes in and fights to protect,

The US will applaud me for these comments around the world its might be different, i say each to the know and there own.

To me Excel know no right or wrong or even care who we are it just *does*

Bill Jelens comments that mr excel to those reading who do not communicate will our friend Bill, looks like the enemy is *within* a common falling.

Lets hope sense will be soon, as i will never except Microsoft staff would ever be a low to be aggressive to less competent users, Bill Gates im sure would see to this at a stop.

Im saddened a guy who can and does work at Microsoft does this and he shows such knowledge but abuses this, and silly allows a track on him>> all the strong comments to make suck a mundane error of judgement.

Im saddened..

I would LOVE to work for Microsoft!

__________________
Free Excel based Web Toolbar available here.

Jack in the UK
J & R Excel Solutions
"making Excel work for you"
Jack in the UK is offline   Reply With Quote
Old May 17th, 2002, 11:15 PM   #9
Mood
New Member
 
Join Date: Mar 2002
Location: Manitoba, Canada
Posts: 22
Default

Quote:

I would LOVE to work for Microsoft!

Jack,

Everybody on this board is employed by M$.

I am not the only one who gets XL'ent ideas from reading the posts. We are all contributing to the next version of XL in one way or another.

Peter
Mood is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 02:03 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
All contents Copyright 1998-2012 by MrExcel Consulting.
diabetic desserts recipes recipes Diabetic Soups Holiday Pizza Recipes Popcorn Recipes Recipes For Microwave Pasta Recipes Casserole Recipes Chili Recipes Curry Recipes Crockpot Recipes Apples Recipes Bread Recipes Vegetarian Recipes Vegetable recipes Desserts Recipes Appetizers Ethnic Recipes Meat Dishes Barbecue Recipes Sauces Recipes Marinade Recipes Low Fat Recipes Frugal Gourmet Kitchen Classics Recipes On The Grill Cook Books Seafood Recipes Cajun Recipes Breads Low Fat Low Fat Breads Bread Machine Recipes Yeast Breads Quick Breads Fat Free Vegetarian Salad Recipes Eggplant Recipes Radish Recipes Tomato Recipes Jalapeno Recipes Potato Recipes Lettuce Recipes Cabbage Recipes Beans Ambrosia Recipes Biscotti Recipes Desserts Low Fat Cookie Recipes Cheesecake Recipes Cake Recipes Pie Recipes Muffin Recipes Custard Recipes Best Appetizers Appetizers Low Fat Salsa Recipes Dip Recipes International Recipes Afghan Recipes Alaska Recipes French Recipes German Recipes Greek Recipes Italian Recipes Spanish Recipes Thai Recipes Korean Recipes Chinese Recipes Mexican Recipes Indian Recipes Beef Recipes Pork Pork & Ham Pork Butts Pork Chop Recipes Pork Ribs Rulled Pork Poultry Recipes Stews Recipes Ground Beef Barbecue Grill Barbecue Smoker All Purpose Sauce BBQ Sauce Barbecue Sauce Carolina BBQ Sauce Pickle Recipes Marinades Smoking Low Fat Appetizers & Dips Low Fat Breakfast Low Fat Cakes Low Fat Cheesecakes Low Fat Cookies Low Fat Desserts Low Fat Fish & Seafood Low Fat Meats Low Fat Pasta Low Fat Pies Low Fat Salads Low Fat Sandwiches Low Fat Sauces & Condiments Low Fat Sides Low Fat Soups Low Fat Vegetarian Baker's Dozen Taste of Home Recipe Book Bon Appetit Cookbook Blacktie Cookbook Buster Cook Book Cookbook USA Cook Book Cook Book Sara's Cookbook Sara's Cookbook Appetizers and Dips Poultry recipes Diabetic recipes Holiday recipes Miscellaneous recipes 110 recipes 1986 Usenet cookbook 2900 recipes Cyberrealm recipes Great sysops of world Specialty recipes Ceideburg recipes Cheese recipes Chili recipes Fruits recipes Garlic recipes Great chefs of NY Londontowne recipes Raisins recipes Recipes for kids US Food Vegetarian recipes Bread recipes Drinks Meat Dishes Brisket recipes Caribou recipes Chicken recipes Filet mignons recipes Pork recipes Swordfish recipes Turkey recipes Pasta recipes Uncategorized recipes Ethnic recipes Canada recipes English recipes Ethiopia recipes Germany recipes Greece recipes Mexican recipes Philippines recipes Welsh recipes Microwave recipes Soups recipes Vegetable recipes Asparagus recipes Barley recipes Brown rice recipes Lentil recipes Mushrooms recipes Salads recipes Wild rice Desserts recipes Cakes recipes Chocolate recipes Cookies recipes Ice cream recipes