Need help with date input

M

m1918

I have always like to format my date to show as year-month-day (2006-06-15). I have set it to show in that format
whenever I hit Control + : within a cell where I would like to have today's date shown. It has been working without any
problem until yesterday. Now whenever I want a date and hit the usual key combination, I will get what I want only after I
press Enter or Return. Prior to that, the date is displayed as month-day-year (6/15/2006) instead. That might not seem
like a big problem, but in reality I usually want to change the day to a day early or a day later. I was able to
backspace to delete the last number and enter what I want. But now with the year being the last item, I will have to
backspace to the middle where the day is before I can edit it. Since I do need to change the day many times in a day. It
does get annoying to have to hit the keys (backspace) a few more times everytime.

So, can anyone show where I could possiblily change the date format back to what I used to have. I'm not sure if it has
to do with Excel or OS X. I just want to be able to get a date showing up in a cell as 2006-06-15 even before I hit the
Return key.

I'm using Excel 2004 for Mac and Mac OS 10.4.6.


Thanks in advance.

gm
 
G

gls2815

gm,

I'm not the macro expert, but I do know this one. It sounds like you
had a custom date macro in whatever document you were working on, and
it is possible that you either disabled the macros at the document open
prompt or you are using a new workbook file that does not contain the
custom macro. If you remember clicking "disable macros" when opening
the file, go back and open it with macros enabled this time and your
custom date macro should start working again.

If not, you can use this code to recreate your custom macro:

Sub ChangeDate1()
ActiveCell.Value = Now
Selection.NumberFormat = "yyyy-mm-dd"
End Sub

And assign a keyboard combination to it via the Macros dialog under
Tools. Since you need a macro that skips a day ahead and a day behind,
just make two macros of the one above and modify the procedure line to
read:

ActiveCell.Value = Now + 1
or
ActiveCell.Value = Now - 1

and assign them two different keyboard combinations. That should solve
your problem.

G
 

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

Similar Threads


Top