A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Im really frustrated with your responses to be honest because they do not assist in any way with my problem
Well, I don't understand why you don't want to understand how Excel works.
Perhaps it is helpful if we both take a step back and take a look at how Excel works, without any text conversation.
A date in Excel is a number, if we want to store a date into a cell, we have to store a number.
Make a new file and execute this code:
Sub Test()
Dim i As Long
For i = 1 To 30
With Range("A" & i)
.Value = 54321
.NumberFormat = "[$-" & i & "]ddd dd/mmm/yyyy"
End With
Next
End Sub
You can format the cells in A1 with any date format you like, works.
In an exaggerated example, I can show what I'm saying and what you're trying, please execute that:
Sub Test2()
'What I suggest
With Range("C1")
.Value = 54321
.NumberFormat = "[$-F800]dddd, mmmm dd, yyyy"
End With
'What you try
Range("C2") = "Sonntag, 20. September 2048"
End Sub
You try to store a date as text (in a slightly different way using FORMAT) and that did not work.
C2 is a text, C1 is a real date.
If you write a text into a cell that looks like a date, Excel tries to convert the text into a number:
Sub Test3()
'What you try in fact:
Range("E1") = "20/02/03"
Range("E2") = "01/20/03"
Range("E3") = "01/02/30"
End Sub
It depends on the regional Office settings and/or the local PC what's the result:
My local format is dd.mm.yyyy
As you see, on my PC only E2 and E3 are converted into a real date, the conversation failed with E1 and Excel stores a text. That looks a bit curious because 20. Feb. 2003 is a valid date...
But that's the way how Excel works. And that is also the situation in your database, text and dates are mixed up.
You can't use the FORMAT function to store a date into a cell. That's the point. Either you understand that or I can't help you.
Andreas.