Macro for auto date/time stamp

G

Guest

I am trying to write a macro that I can assign to a button that when pressed,
will insert the current date and time in cell B7 on a sheet named
"Project-1". Please note that the button will be located on a different
sheet other than "Project-1". I would greatly appreciate any help in writing
this macro (I'm just starting to learn VBA). Thanks in advance for any help.
Bob
 
R

Ron de Bruin

Use this Bob

Sheets("Project-1").Range("B7").Value = Format(Now, "dd-mmm-yy hh-mm-ss")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top