View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default how to reccognize what day is it ?

Dim dt as Date
dt = DateValue("08-17-2006")

Now if you want to calculate with the day of the week

iday = weekday(dt) '

if you want to display Thursday

sday = Format(dt,"dddd") ' Thursday
or
sday = Format(dt,"ddd") ' Thu


demo'd from the immediate window:

dt = DateValue("08-17-2006")
? weekday(dt)
5
? format(dt,"dddd")
Thursday
? format(dt,"ddd")
Thu


--
Regards,
Tom Ogilvy


"vumian" wrote:


hi everyone,

if i have date 08-23-2006, how to check it what day is it

example: 08-17-2006, today is thursday

thanks in advance


--
vumian
------------------------------------------------------------------------
vumian's Profile: http://www.excelforum.com/member.php...o&userid=36494
View this thread: http://www.excelforum.com/showthread...hreadid=572676