+ Reply to Thread
Results 1 to 2 of 2

Cmd ; to insert time runs as a value rather than an action?

  1. #1
    Registered User
    Join Date
    12-27-2013
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    1

    Cmd ; to insert time runs as a value rather than an action?

    Hi Guys.

    Any help with this appreciated.

    I'm running a clock in an excel sheet that refreshes every second which is fine. I then have a macro button that when clicks I want to insert a static time. Now() isn't any good here. I thought I had it sorted by using Cmd ; to insert the time but when I recorded the macro and looked at the code it's just putting in the static value from the time I recorded the macro and not the time, and each time the button is activated. Is there a way that cmd ; can be coded into a macro?

    Thanks in advance (toughie!)

    G

  2. #2
    Forum Expert
    Join Date
    10-09-2014
    Location
    Newcastle, England
    MS-Off Ver
    2003 & 2013
    Posts
    1,831

    Re: Cmd ; to insert time runs as a value rather than an action?

    I assume that when you say you cant use Now() you mean in a cell formula ie =Now() which would just keep refreshing.

    Try this...

    it uses Now() rather than Cmd
    Attached Files Attached Files
    If someone has helped you then please add to their Reputation

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. vba code throws an error first time but runs perfectly the second time. HELP!!
    By mvneema in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-29-2014, 12:42 PM
  2. Macro doesn't run first time but the second time it runs perfect
    By flunzy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-19-2013, 11:00 AM
  3. Macro that runs at a certain time based on time in a cell
    By ScabbyDog in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-11-2012, 12:37 PM
  4. check for insert row action...
    By mark kubicki in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-25-2006, 08:10 PM
  5. [SOLVED] Insert Date that Macro runs
    By jhahes in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 08-05-2005, 07:05 PM

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