#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 45
Default Date Display

How can I configure a cell so that I can enter 11152007 as a date and have it
display as 11/15/2007?

Thanks,

patty
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Date Display

You can use another cell:
=DATE(RIGHT(D23,4),LEFT(D23,2),MID(D23,3,2))

or you can use VBA to do the same thing in a single cell.
--
Gary''s Student - gsnu200756


"Patty" wrote:

How can I configure a cell so that I can enter 11152007 as a date and have it
display as 11/15/2007?

Thanks,

patty

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 45
Default Date Display

What is VBA?

"Gary''s Student" wrote:

You can use another cell:
=DATE(RIGHT(D23,4),LEFT(D23,2),MID(D23,3,2))

or you can use VBA to do the same thing in a single cell.
--
Gary''s Student - gsnu200756


"Patty" wrote:

How can I configure a cell so that I can enter 11152007 as a date and have it
display as 11/15/2007?

Thanks,

patty

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,268
Default Date Display

If it is only for display and not for any calculations whatsoever you can
use a custom format like

00\/00\/0000

and it will display as you want



if you really want a date that Excel will read as a date you would need
either a help cell with a formula like

=--TEXT(A1,"00\/00\/0000")

then format that cell as a regular date

or you can use an event macro

http://www.cpearson.com/excel/DateTimeEntry.htm


--


Regards,


Peo Sjoblom




"Patty" wrote in message
...
How can I configure a cell so that I can enter 11152007 as a date and have
it
display as 11/15/2007?

Thanks,

patty



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Date Display

It is a language available to Excel to allow automation of steps you do
manually. For example:

Private Sub Worksheet_Change(ByVal Target As Range)
Set t = Target
Set r = Range("A1")
If Intersect(t, r) Is Nothing Then Exit Sub
v = t.Text
Dim d As Date
d = DateSerial(Right(v, 4), Left(v, 2), Mid(v, 3, 2))
Application.EnableEvents = False
r.Value = d
Application.EnableEvents = True

will wait until you enter the number in A1 and then change it to a date.
This way only one cell is used, not two.
--
Gary''s Student - gsnu200756


"Patty" wrote:

What is VBA?

"Gary''s Student" wrote:

You can use another cell:
=DATE(RIGHT(D23,4),LEFT(D23,2),MID(D23,3,2))

or you can use VBA to do the same thing in a single cell.
--
Gary''s Student - gsnu200756


"Patty" wrote:

How can I configure a cell so that I can enter 11152007 as a date and have it
display as 11/15/2007?

Thanks,

patty

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Formula to Display Date n-Workdays from a Certain Date BHadds Excel Discussion (Misc queries) 4 June 13th 07 09:49 PM
display date eesh New Users to Excel 2 February 26th 07 12:26 PM
date display pamwp Excel Discussion (Misc queries) 2 February 5th 07 03:20 PM
X axis date - display beyond latest date. Dave F. Charts and Charting in Excel 1 January 3rd 07 03:17 AM
Date display new2XL Excel Discussion (Misc queries) 1 June 14th 06 04:33 PM


All times are GMT +1. The time now is 08:08 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"