Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
I just wrote a function that returns a variant, instanced as either a string
("N/A") or a date. But I noticed it appears as a number in the spreadsheet. So I figure I could format the cell right within the function, using: ActiveCell.NumberFormat = "yyyy-mm-dd" It doesn't work. When I insert after this statement, the following: debug.print (ActiveCell.NumberFormat) I find that it is still general. The odd thing is, if I write another function that only sets the active cell to the proper format, it works fine. Any ideas? Dom |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Difference in the listing of the New module addition in 2002 version | Excel Discussion (Misc queries) | |||
Access Module coded converted to Excel Function | Excel Discussion (Misc queries) | |||
Setting macro security level to "low" permanently? | Excel Discussion (Misc queries) | |||
Setting default pivot table field setting to "sum" | Excel Discussion (Misc queries) | |||
Is there any specific setting for MS excel to download CSV in fin. | Excel Discussion (Misc queries) |