Hi there,
I've been trying unsuccessfully to write a function that converts a DATE to TEXT(String) in the following format: yyyy-mm-dd
example, say the user enter: 10-May-06, the function should return this value: 2006-05-10
thanks for any help
Hi there,
I've been trying unsuccessfully to write a function that converts a DATE to TEXT(String) in the following format: yyyy-mm-dd
example, say the user enter: 10-May-06, the function should return this value: 2006-05-10
thanks for any help
You can pre-format the cell as yyyy-mm-dd then it would display that way.....or if you want a formula in another cell try
=TEXT(A1,"yyyy-mm-dd")
where your date is in A1
Thanks!!!!
it works on the spreadsheet. So assuming the input from the user is type DATE
how would the function would look like?
(the code below doesn't work)
Function convert_date(myDay As Date)
convert_date=TEXT(myDay ,"yyyy-mm-dd")
End Function
thank you for your help
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks