+ Reply to Thread
Results 1 to 10 of 10

Macro to calculate % then multiply by another cell

  1. #1
    Registered User
    Join Date
    02-05-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    8

    Macro to calculate % then multiply by another cell

    Hi,

    I need a macro in column D to calculate the % for column B&C and then multiply it by a number in column A (number may change). I have been manually doing the calculations every month with over thousand of records. Is it possible to do it?

    Attached please find the sample file. Thanks.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro to calculate % then multiply by another cell

    Maybe:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    02-05-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Macro to calculate % then multiply by another cell

    It works!......THANK YOU VERY MUCH!!!

  4. #4
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro to calculate % then multiply by another cell

    You're welcome. Glad to help out and thanks for the feedback. Please comply with Forum Rule No. 9.


    9. Acknowledge the responses you receive, good or bad. If your problem is solved, please say so clearly, and mark your thread as Solved: Click Thread Tools above your first post, select "Mark your thread as Solved". Or click the Edit button on your first post in the thread, Click Go Advanced, select [SOLVED] from the Prefix dropdown, then click Save Changes. If more than two days have elapsed, the Dropdown option or Edit button will not appear -- ask a moderator to mark it.

  5. #5
    Registered User
    Join Date
    02-05-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Macro to calculate % then multiply by another cell

    Hi, John:

    When the macro runs to the end of my file, there's an error message (Run-time error "13": Type mismatch) and the "ActiveCell.Offset(, 3).Value = ActiveCell.Offset(, 1).Value / z * y" is highlighted. Can you please let me know how to fix it? Thanks.

  6. #6
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro to calculate % then multiply by another cell

    Rosanna:

    When I test it on the sample provided, I can't duplicate the error. Can you provide a sample where it errors?

  7. #7
    Registered User
    Join Date
    02-05-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Macro to calculate % then multiply by another cell

    Thanks, John. Please see attached.
    Attached Files Attached Files

  8. #8
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro to calculate % then multiply by another cell

    OK try:

    Please Login or Register  to view this content.

  9. #9
    Registered User
    Join Date
    02-05-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    8

    Thumbs up Re: Macro to calculate % then multiply by another cell

    Thank you!!!

  10. #10
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro to calculate % then multiply by another cell

    You're welcome.

+ 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. [SOLVED] Multiply, Divide and Then Multiply in a cell
    By Brownie2576 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 10-22-2012, 08:57 PM
  2. Macro / VB - copy cell, paste value and multiply by X
    By Supersmithy in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 03-21-2012, 08:07 AM
  3. Calculate combis and then multiply by cell values
    By faris al farik in forum Excel General
    Replies: 1
    Last Post: 01-28-2012, 06:17 PM
  4. Macro to multiply a no entered in a cell with a constt no then replace with result
    By deepakya3 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-30-2011, 07:21 AM
  5. calculate time and multiply it by $ amount
    By DR in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-08-2006, 02:40 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