+ Reply to Thread
Results 1 to 2 of 2

Need to calculate a product based on a date (MAY NEED VBA)

Hybrid View

  1. #1
    Registered User
    Join Date
    03-08-2017
    Location
    New York, NY
    MS-Off Ver
    2013
    Posts
    7

    Lightbulb Need to calculate a product based on a date (MAY NEED VBA)

    This one is a little intricate...

    Capture.PNG

    The boxes numbered 1-5 correspond with years. So if we're in 2017, 1 is 2017, 2 is 2018, 3 is 2019.... The number underneath it is the new rent number.

    In the box that says Current Monthly Rent, I need the cell to 1) determine if =YEAR() fits between the range of "Lease Begins" and "Lease Ends", 2) determine if it is the first period (2017 =1), second period (2018=2), ...., and then 3) based on what the date is, multiply the relative number under RSF by the relative number under the period.

    In example..

    If today is 1/1/2018, then we are in the second period of lease for "Store", and I need the Current Monthly Rent to return ($22.00*1,800).


    Please instruct how this could be done, if it needs VBA, please advise what to do as I am not a programmer.

    Thanks!
    Attached Files Attached Files
    Last edited by reanalyst; 03-08-2017 at 05:59 PM. Reason: added workbook

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,047

    Re: Need to calculate a product based on a date (MAY NEED VBA)

    Hi, welcome to the forum

    To best describe or illustrate your problem you would be better off attaching a dummy workbook. The workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook.

    To attach a file to your post,
    click advanced (next to quick post),
    scroll down until you see "manage file",
    click that and select "add files" (top right corner).
    click "select files" find your file, click "open" click "upload" click 'done" bottom right. click "submit reply"

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ 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. How to calculate USD based on product, sales volume, consumption cost
    By ChrisNor in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 06-23-2016, 08:36 AM
  2. [SOLVED] Get product code and quantity based on date
    By BRISBANEBOB in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-08-2016, 12:55 AM
  3. [SOLVED] calculate expiry date automatic according to product name
    By mazan2010 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-11-2016, 02:01 PM
  4. Check a value based on product code and date
    By DirectGardenBuilding in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 10-27-2013, 05:33 AM
  5. Replies: 2
    Last Post: 03-15-2012, 12:11 AM
  6. Sum Product based on Date
    By Christopherdj in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-05-2012, 08:17 PM
  7. count product based on date
    By sc11 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-14-2012, 08:37 AM

Tags for this Thread

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