Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
I am new to excel. This may be the stupidest question of all time, but I would like to know how to assign, program, or whatever you call it in excel a date to a key so that when I am in a cell and want to enter that date all I have to do is use one keystroke. For example, can I somehow assign a date like 07/26/08 to the F10 key so that every time I press F10 the date 07/26/08 is entered into the cell where the cursor is?
Thanks in advance for any help you can provide me. |
#2
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]()
This may not be exactly what you're looking for, but to enter the current
date in a cell click Control + ;. If you're entering 7/26/08 in multiple cells you could copy (the text) and select the cells you want it in by holding Control and clicking on them, then paste. I hope that is somewhat helpful. Best wishes! "barefoot" wrote: I am new to excel. This may be the stupidest question of all time, but I would like to know how to assign, program, or whatever you call it in excel a date to a key so that when I am in a cell and want to enter that date all I have to do is use one keystroke. For example, can I somehow assign a date like 07/26/08 to the F10 key so that every time I press F10 the date 07/26/08 is entered into the cell where the cursor is? Thanks in advance for any help you can provide me. -- barefoot |
#3
![]()
Posted to microsoft.public.excel.newusers
|
|||
|
|||
![]()
Select a blank cell anywhere on your worksheet.
Go to Tools - Macro - Record New Macro. Choose a character to enter into the box for a Shortcut Key. Click OK. Type the date you want to enter. Click the check mark next to the edit area at the top to complete your data entry. Click the stop button on the macro recorder toolbar that appeared when you started recording. Now check your code. Click Alt+F11 to open the code. Double-click the "Modules" folder. Double-click "Module1" to look at the code. You should see something like: Sub Macro1() ' ' Macro1 Macro ' Macro recorded 8/13/2008 by Trevor M. Sides ' ' Keyboard Shortcut: Ctrl+d ' ActiveCell.FormulaR1C1 = "7/26/2008" End Sub Remove any other code, especially things like: Range("D15").Select You can repeat this for as many shortcut dates as you want. You must record the macro for each one, though, copy/pasting that code and changing the Keyboard Shortcut line doesn't actually create the shortcut. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Not enough room to enter dates | Excel Discussion (Misc queries) | |||
Formula to Enter Dates | Excel Discussion (Misc queries) | |||
how to enter sortable dates before 1900 | Excel Discussion (Misc queries) | |||
How to NOT enter dates? | New Users to Excel | |||
How to enter dates? | New Users to Excel |