View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Ron Coderre
 
Posts: n/a
Default Is it possible to create your own custom format?

Would something like this work for you?:

First, create a lookup table for the days:

Example (using French):
D1: Mon
E1: Lundi
D2: Tue
E2: Mardi
(etc)

For a date in A2:
B2: =VLOOKUP(TEXT(A2,"ddd"),D1:E7,2,0)

Does that help?

***********
Regards,
Ron


"Scott Steiner" wrote:

Hi,

I have a column that represents the weekday (number from 1-7) of a date
by using the worksheet weekday function. I used the custom format "dddd"
on that column to display the values as days (Sunday, Monday, ....)
rather than numbers.

Question: I want to display the days in a different language without
having to change the regional code of the PC. Is it possible to create
my own custom format that changes the way the column is displayed
_without_ changing the underlying value which is a number from 1-7?

I tried writing my own weekday function which displays fine but the
problem is that it also changes the underlying value of the cells which
I don't want to do as this affects other calculations.

Thanks for any help on how to tackle this problem!