Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
Is there a way to have excel automatically add a new date to the end of a
column each day? My goal is to have an automatic date in column A and daily closing prices for the S&P500(in column B) corresponding to those dates that are updated via web query. Thanks so much! |
#2
![]() |
|||
|
|||
![]()
Maybe...
Option Explicit Sub auto_open() Dim LastCell As Range With Worksheets("Sheet1") Set LastCell = .Cells(.Rows.Count, "A").End(xlUp) If LastCell.Value = Date Then 'already opened and populated 'do nothing Else With LastCell.Offset(1, 0) .Value = Date .NumberFormat = "mm/dd/yyyy" End With End If End With End Sub If you're new to macros, you may want to read David McRitchie's intro at: http://www.mvps.org/dmcritchie/excel/getstarted.htm (I have no idea about the query, though.) willray wrote: Is there a way to have excel automatically add a new date to the end of a column each day? My goal is to have an automatic date in column A and daily closing prices for the S&P500(in column B) corresponding to those dates that are updated via web query. Thanks so much! -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Calculating number of days between two dates that fall between two other dates | Excel Discussion (Misc queries) | |||
Automatic shading of cells based on dates??? | Excel Worksheet Functions | |||
2 digit year in dates return 19xx not 20xx | Excel Discussion (Misc queries) | |||
Default Dates | Excel Discussion (Misc queries) | |||
Formating Dates for production schedule | Excel Discussion (Misc queries) |