Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
I have a userform where two dates are entered into some textboxes. In the code these are processed a bit and should be returned to a sheet as parameters in a query. The problem is, that they are returned as mm/dd/yyyy and not dd/mm/yyyy as I need them. The code, that returns the values is: .... Dim LowerDate, UpperDate As Date intSpm = valSpm .... With Sheets("DataAnswers") With Range("UpperDate") .Value = UpperDate .NumberFormat = "d/m/yyyy" End With With Range("LowerDate") .Value = LowerDate .NumberFormat = "d/m/yyyy" End With .Range("Question").Value = intSpm End With The date 10-01-2007 (10th Jan, 2007) is returned as 01-10-2007 (1st Oct, 2007) whereas 26-06-2007 (26th Jun, 2007) is returned correctly. What to do in Excel 2003, UK?!? Thanks, /Sune |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Error Handling | Excel Programming | |||
error handling | Excel Programming | |||
Error handling. | Excel Programming | |||
Handling Dates in VLookup | Excel Programming | |||
Error handling with a handling routine | Excel Programming |