Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi
I have set in program cell(x,2).numberformat = Dateserial(dd-mm-yy). but while running program if cells(x,2).value= cells(x.2)+1 or cells(x,2). value=Dateserial(yr+1,mth,dt), or cells(x,2).value=Dateserial(yr,mth,dt+1) etc is done not always working properly if tody it works tomorrow it won't A kinder garten type question, I know . still i long for help thanks -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...mming/200911/1 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The value returned from the DateSerial function is a Date, not a String...
the NumberFormat property requires a (format pattern) String. Try it this way... Cell(x, 2).NumberFormat = "dd-mm-yy" -- Rick (MVP - Excel) "evelin via OfficeKB.com" <u54234@uwe wrote in message news:9ef199870fda6@uwe... hi I have set in program cell(x,2).numberformat = Dateserial(dd-mm-yy). but while running program if cells(x,2).value= cells(x.2)+1 or cells(x,2). value=Dateserial(yr+1,mth,dt), or cells(x,2).value=Dateserial(yr,mth,dt+1) etc is done not always working properly if tody it works tomorrow it won't A kinder garten type question, I know . still i long for help thanks -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...mming/200911/1 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi Rick Rothstein
Thanks i have to try that -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...mming/200911/1 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
date confusion | New Users to Excel | |||
Sorting pivot tables - text / date confusion | Excel Discussion (Misc queries) | |||
date confusion | Excel Programming | |||
Confusion..... | Excel Discussion (Misc queries) | |||
Date vs h:mm:ss confusion | New Users to Excel |