0

When I open notepad, I can press F5 to give me the time in the format I desire and then the date in the format I desire, where the formats I desire are based on windows settings.

The only thing missing is to have date and time interchanged.

How do I do this please?

  1. Well one way is to press F5, press space, press F5 again and then copy/cut/delete as appropriate, but...

  2. I'm hoping to have date and time with only 1 (or 2 or 3) button(s).

  3. I have a razer mouse, and I can create/import macros, but this seems like a wheel reinvention and kind of a hassle.

  4. I discovered autohotkeys and posted an answer below, but I'm hoping for something simpler.

Please suggest something simpler, such as adjusting notepad settings to give me date 1st then time.

1 Answer 1

0

Ok so the tags informed me of the existence of AutoHotKeys, so here's an answer:

  1. Using notepad, create a file named for example date&time.ahk (save as a '.ahk' file)

  2. Here's an example

Put this in the file

(insert desired hotkey)::
FormatTime, DateTimeString,, (insert desired timestamp format)
Send, %DateTimeString%
return

For example

^XButton2::
FormatTime, DateTimeString,, ddd yyyyMMMdd h:mmtt
Send, %DateTimeString%
return

The hotkey is ctrl(the ^)+mouse4(the XButton2), and the output looks like:

Thu 2020Jun11 7:35am

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .