+ Reply to Thread
Results 1 to 2 of 2

Remove positive and negative duplicates

  1. #1
    Registered User
    Join Date
    05-02-2014
    Location
    houston, texas
    MS-Off Ver
    Excel 2003
    Posts
    1

    Remove positive and negative duplicates

    I am currently working on a project whereby I need to remove duplicate rows (containing both a positive and negative number). I've tried a few different formulas and macros but I'm running into a problem. It's wanting to remove ALL positive matches instead of one.

    For example: Column BH has -4,4,4,-2,2,-1,1,

    I need it remove those numbers that cross cancel and keep the one that doesn't have a partner.

    Can anyone help?

    Side note: Column A has an owner code, Column B a well code, and BH is the amount due. I need it to bare this in mind as well. I hope someone knows how to make this happen.

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Remove positive and negative duplicates

    Try this user defined function

    Please Login or Register  to view this content.
    Open the VBA editor by hitting Alt F11.
    Insert a new module with Insert - Module
    Paste in the above function
    Go back to the sheet by hitting Alt F11.

    In a suitable cell in row 1, enter =RemoveIfCrossCancel(BH1)

    Remember to save the workbook as a macro enabled workbook .xlsm
    Martin

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 0
    Last Post: 03-12-2014, 05:31 PM
  2. Higlight duplicates positive and negative numbers
    By magman1984 in forum Excel - New Users/Basics
    Replies: 9
    Last Post: 02-13-2014, 01:07 PM
  3. Replies: 2
    Last Post: 09-03-2013, 09:18 AM
  4. Convert negative to positive in sheet containing both positive/negative numbers
    By sa02000 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-29-2010, 07:52 PM
  5. Replies: 2
    Last Post: 11-13-2008, 12:35 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1