+ Reply to Thread
Results 1 to 6 of 6

Keeping percentages at or below 100

  1. #1
    Forum Contributor
    Join Date
    11-17-2004
    MS-Off Ver
    Office 2016
    Posts
    527

    Keeping percentages at or below 100

    I have a spreadsheet that performs some financial mortgage calculations. This sheet has 2 sets of fields where you can enter a dollar amount and a corresponding percentage is calculated (using a constant value for calculations), OR you could enter the percentage and the corresponding dollar amount is calculated. The problem I now have is that it’s possible to enter two percentages, or dollar amounts, where the total of the 2 sets of numbers exceed 100% of the constant value.

    How can I force the percentage (and therefore the dollar amount) of the other set of numbers to change if I enter a percentage (or dollar amount) that causes the total to exceed 100%. The change should cause the total percentage to be 100%.

    The fields that I’m in need of fixing are the Down Payment and Loan Amount fields.

    A sample worksheet is attached.
    Attached Files Attached Files
    Last edited by JimDandy; 10-24-2010 at 12:32 AM.

  2. #2
    Registered User
    Join Date
    10-18-2010
    Location
    chicago
    MS-Off Ver
    Excel 2003
    Posts
    16

    Re: Keeping percentages at or below 100

    Jim,
    Could you send a workbook that doesnt have links - just the formulas you are using?
    Teddy

  3. #3
    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: Keeping percentages at or below 100

    Hi Jim

    I've tested this on your basic data. See if the code works for you.
    Please Login or Register  to view this content.
    Let me know of issues.

    John
    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.

  4. #4
    Forum Contributor
    Join Date
    11-17-2004
    MS-Off Ver
    Office 2016
    Posts
    527

    Re: Keeping percentages at or below 100

    This code is very close....it works when modifying the percentage values, but if I modify the dollar amount, it correctly sets the percentage for that line only, it does not recalculate the percentage/dollar amount for the other set of values.

  5. #5
    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: Keeping percentages at or below 100

    Hi Jim

    You've got a lot of stuff going on here. It's getting late but I'll take one last shot before bed
    Please Login or Register  to view this content.
    Let me know of issues. I'll look at it again tomorrow.

    John

  6. #6
    Forum Contributor
    Join Date
    11-17-2004
    MS-Off Ver
    Office 2016
    Posts
    527

    Re: Keeping percentages at or below 100

    I think you nailed it that time....many thanks!

    I will point out that there is one correction I made from what I cut here. It appears to be a typo, quickly found and corrected. The 14th line has "If Not Is Numeric..." and should be "If Not IsNumeric...". An extra space was added, but otherwise, it seems to work fine once corrected

    I'll look at it again tomorrow and mark it solved if I can't find anything wrong with it, but it appears you got it right. I do appreciate your help.
    Last edited by JimDandy; 10-22-2010 at 01:03 AM.

+ 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