HI,
My string "20250102" and wanted to convert it to OS Date #2025-01-02#
Thanks
Hello @Rohan J ,
To convert a string in the format "20250102" to an OutSystems Date value (#2025-01-02#), you can use the TextToDate() function with the proper string manipulation to match the expected format ("yyyy-MM-dd").
For your example:
TextToDate(Substr("20250102", 0, 4) + "-" + Substr("20250102", 4, 2) + "-" + Substr("20250102", 6, 2))
Explanation:
Hello Rohan,
Here is a related post, you can find more options to achieve it.
https://www.outsystems.com/forums/discussion/87219/change-to-text-date-to-date-format/
Thanks,
Junaid