Home |
Search |
Today's Posts |
#9
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You're right. I was counting in base Q.
Rick Rothstein wrote: Time to visit the eye doctor Dave... I only see two equal signs.<g -- Rick (MVP - Excel) "Dave Peterson" wrote in message ... You have 3 equal signs in that expression. Excel is doing a comparison: cell.Offset(0, 13).NumberFormat = "dd-mm-yy" and evaluates that to true or false. And this portion: sh1.Cells(rw, 4) is assigned that value So maybe: sh1.Cells(rw, 4) = "dd-mm-yy" or cell.Offset(0, 13).NumberFormat = "dd-mm-yy" is what you want???? Eddy Stan wrote: Hi all I am getting date as number, so copied .numberformat = "dd-mm-yy" as shown below sh1.Cells(rw, 4) = cell.Offset(0, 13).NumberFormat = "dd-mm-yy" ' date before i get number atleast, now i get "false". why ? how would i get the dates coming as numbers to date formats like "dd-mm-yy" or "dd ddd.mmm.yy" thanks "Tom Ogilvy" wrote: don't you want to format the cell containing the date? With ActiveCell .Value = "*" .Offset(0, 1).Value = DTPicker1 .Offset(0,1).NumberFormat = "dd-mm-yyyy" .Offset(0, 3).Value = Val(txtMember) End With -- Regards, Tom Ogilvy "Kjeldc" wrote in message ... This just returns the daynumber, not the formati wish. Why oh Why. Please help With ActiveCell .Value = "*" .Offset(0, 1).Value = DTPicker1 ActiveCell.NumberFormat = "dd-mm-yyyy" .Offset(0, 3).Value = Val(txtMember) End With -- Dave Peterson -- Dave Peterson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
DateFormat (dd-mmm-yyyy) (dd-mmm-jjjj) Problem. | Excel Programming |