Using the Excel TEXT function within a VBA program

  • Thread starter Thread starter Bernard.Baz
  • Start date Start date
B

Bernard.Baz

Despite the fact that I am using a French version of Excel
2000, the Excel "Text" function, expects its format
parameters in English and returns a result in English when
used within a VBA 6 instruction.
This is frustrating when dealing with month or day names.
For instance, an instruction such as :
Application.Text(38000,"mmmm aaaa")
returns "january aaaa" instead of "janvier 2004".

I have checked the "International" properties of the
Application. They seem to be set properly :
Daycode is set to "j" (stands for "jour" or day in French)
Yearcode is set to "a" (stands for "année" or year in
French)

Thank 's for help
 
Have you tried it all English form

Application.Text(38000,"mmmm yyyy")

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

message Despite the fact that I am using a French version of Excel
2000, the Excel "Text" function, expects its format
parameters in English and returns a result in English when
used within a VBA 6 instruction.
This is frustrating when dealing with month or day names.
For instance, an instruction such as :
Application.Text(38000,"mmmm aaaa")
returns "january aaaa" instead of "janvier 2004".

I have checked the "International" properties of the
Application. They seem to be set properly :
Daycode is set to "j" (stands for "jour" or day in French)
Yearcode is set to "a" (stands for "année" or year in
French)

Thank 's for help
 
Back
Top