How do I auto-update the cell references in my macro to reflect today's stock data.
I have a stock spreadsheet for which I wrote simple macros. One tab has the source data which is stock prices. The other tab contains simple macros that identify price changes from day 1, price change the last week, and the last month.
The layout of the source data tab is: The date field is in row 1 and each day is in its own column. The stocks are in column A and their daily prices are to the right of them.
The layout of the macro tab (that refers to the source data tab) is: Column A: simple calc of price change from yesterday. Column B has calculates the price change from one week ago. Column C has price change calculation from one month ago.
Currently, I manually update the macro tab calculations to by one cell to the right so that I am including the most recent data.
What changes to the macro can be made to auto-increment the macro to reference today's stock price column cells from the source data tab.
Bookmarks