+ Reply to Thread
Results 1 to 16 of 16

Highlighting Debits and Credits

  1. #1
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Highlighting Debits and Credits

    Good Morning All,

    I have a big project to do at work and I need to find all the debits and credits in the excel file for the particular account that they are in. I would do it manual but i have about 18000 line items which would take hours to go through. Is their a formula that can help me with this? They're are multiple duplicates in the file but i just want the debit and credits in the same account highlighted. The debit and credit numbers are in column H. I need to match the positive number with the negative number. Their can also be a duplicate of the same negative number which I dont need to worry about. As long as one positive and one negative number is highlighted. So in the end all the positve numbers that have duplicates should be highlighted. The debit and credit numbers also have to match the account name and account number which are in column G and F. Let me know if you need more information or if it's confusing. Sometimes my explanations can be a bit confusing. I have also attached a file of what it should look like.
    Attached Files Attached Files
    Last edited by vharjani; 02-24-2012 at 08:50 AM.

  2. #2
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani
    I don't know of a formula but code can probably do as you require. Let me look at it.
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  3. #3
    Forum Contributor excelkeechak's Avatar
    Join Date
    07-21-2008
    Location
    India.
    MS-Off Ver
    2013 /2016
    Posts
    363

    Re: Highlighting Debits and Credits

    hi vharjani,,,,,I think you are doing the reconicilation of accounts....Could you elaborate your requirement for further help....
    THANKS
    ExcelKeechak

  4. #4
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    Okay thank you i appreciate it

  5. #5
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    i just need to highlight debits and credits...im going to have about 18000 line items..most of the 18000 line items are negative numbers with about 200 to 300 items that are positive. I need to match the postive duplicates with the negative duplicates that are in the same account. say i have 50, -50, -50 all labeled in the same account i just need the 50 and 1 of the -50 highlighted. I dunno if that helps explain it better. but its so hard to go through 18000 line items and figure match all the numbers up

  6. #6
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani
    Try this code...let me know of issues.
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    hey i ran the macro on my dummy workbook that i posted at home and for some reason it doesnt seem like it did anything, i couldn't find any highlighting or anything on my dummy workbook could this be because i have version 2007 or do the macro work on any version of excel because at work i have 2010.

  8. #8
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani
    I've attached the file. The code should work on Excel 2007 and later (it's an .xlsm file)
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    good morning, I've tried that code again in my work excel file and it doesn't work. But for some reason the file that you attached on here the code works? Do you know what the problem could be?

  10. #10
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    okay so its working but now the code isn't stopping it just keeps going through the 18000 line items over and over again until i hit esc and then asks me to debug or to end...also going through my excel file it doesn't seem like it found all of the debits and credits it found a good amount but i still went through and found a lot more that weren't highlighted by the code. Do you know what the issue could be with this?
    Last edited by vharjani; 02-14-2012 at 09:04 AM.

  11. #11
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    Okay so i figured out what the code doesn't capture. It doesn't capture numbers that have commas such as 27,122.10 as well as numbers that end in 0...such as 2712.10 or 2710.00. Is their anyway that can be fixed?
    Last edited by vharjani; 02-14-2012 at 09:43 AM.

  12. #12
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani

    Attach a file that demonstrates the error. Please include the code in the file. I'll look at it.

  13. #13
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    Good Morning, I have attached a file with the code in which you can see that the numbers ending with zero and numbers that have commas are not going to be highlighted. Can i just fix this by changing the cell format? or do you have to do something to the code
    Attached Files Attached Files
    Last edited by vharjani; 02-16-2012 at 09:25 AM.

  14. #14
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani

    Format the Cells in Column H as General. You can do it by code or manually and after the procedure runs, change the format back.
    Here's the code to do it with code
    Please Login or Register  to view this content.
    Let me know of issues.
    Last edited by jaslake; 02-16-2012 at 03:47 PM.

  15. #15
    Registered User
    Join Date
    02-09-2012
    Location
    virigina
    MS-Off Ver
    2010
    Posts
    17

    Re: Highlighting Debits and Credits

    Good Morning, The formula that you have provided me freezes my excel everytime. I'm not really sure why. Everytime I use the other formula that you provided me it works fine. I think I may just stick with the original forumla you provided me and just change the format to general. I appreciate your help a lot. Thank you so much for making my work so much easier

  16. #16
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Highlighting Debits and Credits

    Hi vharjani

    You're welcome...glad I could be of help. If that satisfies your need, I'd appreciate it if you'll please mark your thread as "Solved".

    To mark your thread solved do the following:
    - Go to your first post on the thread
    - Click edit
    - Click Advance
    - Just below the word "Title:" you will see a dropdown with the word No prefix.
    - Change to Solved
    - Click Save

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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