+ Reply to Thread
Results 1 to 2 of 2

Select a cell in a row 30 days prior to today's row

  1. #1
    Registered User
    Join Date
    07-13-2012
    Location
    Uniontown, OH
    MS-Off Ver
    2010 Pro
    Posts
    9

    Select a cell in a row 30 days prior to today's row

    This is a simple concept, but I'm at a loss.

    I have a list of dates in column A and stock prices in Column B, both columns grow every day the stock market is open.
    I am looking for a VBA function that will go 30 days prior to today's date and give me the price in column B on that date. I can't just go 30 rows up, because there are gaps for weekends, holidays, and days I may have missed entering data. Also, if there is no exact match for 30 days, it should use the next oldest day closest to 30 days.

    Any help?

  2. #2
    Forum Expert
    Join Date
    07-31-2010
    Location
    California
    MS-Off Ver
    Excel 2007
    Posts
    4,070

    Re: Select a cell in a row 30 days prior to today's row

    Have you tried the lookup funtion. something like this where column C is the dates and Column D is the value

    Please Login or Register  to view this content.

+ 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