Macro to take a cell at a specific time and put it another cell Hello, Is there
ID: 3564370 • Letter: M
Question
Macro to take a cell at a specific time and put it another cell
Hello,
Is there anyway to ccreate a macro that will take a cell at a specific time (lets say midnight every day) and place it in another cell. For instance, lets saay cell A1 has a stock quote that is updating every minute. Can I take the value of cell A1 at midnight and place it in Cell A1 on another sheet? For the next day at midnight then it would take the value of A1 and place it in A2 oon the otther sheet and it would do this on and on every day.
Thanks
Explanation / Answer
Sure you can do thiis. but you need 2 short macros. 1 to do the mmove that you want and another to set the trigger time. So the code would look something like this:
sub MoveTheData()
workbooks("otherwworkbook").sheets(1).range("a1")=thisworkbook.sheets(1).range("a1")
end sub
sub RunAtMidnight()
appliccation.ontime timevalue("00:00:00"),,, "movethedata"
end subb
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.