Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
From VBA I want to write a date into a file a file in the format
YYYY.MM.DD how can I do this? Lars |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Lars
Why not use the ISO format http://www.rondebruin.nl/isodate.htm 1. Dates must be represented in either: a. non-separated form of yyyymmdd (eg 20050330 for 30-Mar-2005) b. separated form of yyyy-mm-dd (eg 2005-03-30 for 30-Mar-2005) -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Lars Schouw" wrote in message ... From VBA I want to write a date into a file a file in the format YYYY.MM.DD how can I do this? Lars |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Ron,
=TEXT(TODAY(),"yyyy.mm.dd") seems to do the stunt.. I need this format since some application have depends on it.. I agree ISO format is much nicer, |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Look out if you also use Non English systems if you use the Text function
yyyy in the Netherlands is jjjj English language Version entry: ="Today is "&TEXT(TODAY(),"yyyy-mm-dd") In English language version the formula returns: Today is 2005-02-23 Fails when the when workbook is open in Dutch language version (year = jaar "jjjj-mm-dd"). With a Dutch language version the formula will return: Today is yyyy-02-23 -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Lars Schouw" wrote in message ... Thanks Ron, =TEXT(TODAY(),"yyyy.mm.dd") seems to do the stunt.. I need this format since some application have depends on it.. I agree ISO format is much nicer, |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks I sometimes have users on Japanese systems.
Is there a nice workaround for that problem ? Lars On May 28, 10:03*pm, "Ron de Bruin" wrote: Look out if you also use Non English systems if you use the Text function yyyy in the Netherlands is *jjjj English language Version entry: ="Today is "&TEXT(TODAY(),"yyyy-mm-dd") In English language version the formula returns: Today is 2005-02-23 Fails when the when workbook is open in Dutch language version (year = jaar "jjjj-mm-dd"). With a Dutch language version the formula will return: Today is yyyy-02-23 -- Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm "Lars Schouw" wrote in ... Thanks Ron, =TEXT(TODAY(),"yyyy.mm.dd") seems to do the stunt.. I need this format since some application have depends on it.. I agree ISO format is much nicer,- Hide quoted text - - Show quoted text - |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Lars
If you do it with VBA it is always working correct Sub test() ActiveCell.Value = Format(Date, "yyyy.mm.dd") End Sub But not with the worksheetfunction -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Lars Schouw" wrote in message ... Thanks I sometimes have users on Japanese systems. Is there a nice workaround for that problem ? Lars On May 28, 10:03 pm, "Ron de Bruin" wrote: Look out if you also use Non English systems if you use the Text function yyyy in the Netherlands is jjjj English language Version entry: ="Today is "&TEXT(TODAY(),"yyyy-mm-dd") In English language version the formula returns: Today is 2005-02-23 Fails when the when workbook is open in Dutch language version (year = jaar "jjjj-mm-dd"). With a Dutch language version the formula will return: Today is yyyy-02-23 -- Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm "Lars Schouw" wrote in ... Thanks Ron, =TEXT(TODAY(),"yyyy.mm.dd") seems to do the stunt.. I need this format since some application have depends on it.. I agree ISO format is much nicer,- Hide quoted text - - Show quoted text - |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
change date format from dd/mm/yyyy to mm/yyyy | Excel Discussion (Misc queries) | |||
How do I save date format: dd mmm yyyy as a csv file? | Excel Discussion (Misc queries) | |||
Date format changes from 'yyyy-mm-dd hh:mm:ss' to 'mm/dd/yyyy' | Excel Programming | |||
how do I change date from mm/dd/yyyy to dd:mm:yyyy format in Excel | New Users to Excel | |||
opening excel file - date format problem: DD/MM/YYYY vs MM/DD/YYYY | Excel Programming |