Creating a Combined Date/Time Shortcut

M

Michael Link

I know Excel provides shortcuts for entering the date (CTRL + ;) and the
time (CTRL + SHIFT + ;), but I really need one that will enter both the date
and time in the same cell at the same time. (Since Excel does provide
formatting for same-cell date and time, it seems kind of odd that there isn't
a shortcut to facilitate entry.) Is it possible to create an entirely new shortcut
that doesn't use macros? (This last point is important, since the workbook is
shared on a network.)

Any help anyone can offer would be much appreciated--I'm getting
desperate. Thanks in advance!
 
R

Ron de Bruin

Why not use this

Ctrl-;
press the space bar
Ctrl-:
Enter


--
Regards Ron de Bruin
http://www.rondebruin.nl



I know Excel provides shortcuts for entering the date (CTRL + ;) and the
time (CTRL + SHIFT + ;), but I really need one that will enter both the date
and time in the same cell at the same time. (Since Excel does provide
formatting for same-cell date and time, it seems kind of odd that there isn't
a shortcut to facilitate entry.) Is it possible to create an entirely new shortcut
that doesn't use macros? (This last point is important, since the workbook is
shared on a network.)

Any help anyone can offer would be much appreciated--I'm getting
desperate. Thanks in advance!
 
G

Guest

I thought of that, but (believe it or not) I've had comments from users that
that was too cumbersome. I've seen way too many cell misentries where (for
example) the space was omitted, rendering the cell unusable for calculations
unless I went in and fixed them manually. I really need a single shortcut to
ensure consistent entry with absolutely minimal errors.

I really appreciate the feedvback, though! Thanks!
 
R

RagDyeR

Have you tried:

<Ctrl> <;> <SpaceBar> <Ctrl> <Shift> <:>
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================

I know Excel provides shortcuts for entering the date (CTRL + ;) and the
time (CTRL + SHIFT + ;), but I really need one that will enter both the date
and time in the same cell at the same time. (Since Excel does provide
formatting for same-cell date and time, it seems kind of odd that there
isn't
a shortcut to facilitate entry.) Is it possible to create an entirely new
shortcut
that doesn't use macros? (This last point is important, since the workbook
is
shared on a network.)

Any help anyone can offer would be much appreciated--I'm getting
desperate. Thanks in advance!
 
G

Guest

Thanks for the fast feedback--but I don't think that's going to do it for me.
(See my response to Ron de Bruin, below.) If you have any other ideas, I'd
really appreciate it!
 
R

Ron de Bruin

You must use a macro then

--
Regards Ron de Bruin
http://www.rondebruin.nl



I thought of that, but (believe it or not) I've had comments from users that
that was too cumbersome. I've seen way too many cell misentries where (for
example) the space was omitted, rendering the cell unusable for calculations
unless I went in and fixed them manually. I really need a single shortcut to
ensure consistent entry with absolutely minimal errors.

I really appreciate the feedvback, though! Thanks!
 
D

Dave Peterson

If the problem with the macro and shared workbook is that you can't add any
procedures without unsharing the workbook, then how about adding another
workbook on that shared drive.

It's sole purpose would be to provide that shortcut.

After you create that workbook, you could hide it (windows|hide), close excel
and answer yes to the save prompt. Then the workbook will open hidden and
nobody will even know it's there.

Yes, the users will have to open it -- but just make that a training issue!

Here's some sample code that may get you started:

Option Explicit
Sub auto_open()
Application.OnKey "^T", "DoTimeDate"
End Sub
Sub auto_close()
Application.OnKey "^T"
End Sub
Sub DoTimeDate()
On Error Resume Next
With Selection
.NumberFormat = "mm/dd/yyyy hh:mm:ss"
.Value = Now
End With
On Error GoTo 0
End Sub


The shortcut is: ^T (control-shift-t (ctrl-T))
 
Top