Get DateTime Android Bug ?


I would like to create a daily reward, and for that I need the compare DateTime. On the Unity Editor, that’s works PERFECTLY, but when I export my apps into Android the code stuck with the “Parse” method

I’ve created a Textbox to understand when the code stop to works : ‘DebugText’

void Start()
            DebugText.text = "Debug " + DateTime.Now.ToString("dd/MM/yyyy");
            DateTime todaysDate = DateTime.Parse(DateTime.Now.ToString("dd/MM/yyyy"));
            DebugText.text = "Debug " + "TodayOK : ";

As result I have only “29/05/2020”, and not “TodayOK” and all code after that are not played.
I’ve tried with

DateTime todaysDate = Convert.ToDateTime(DateTime.Now.ToString("dd/MM/yyyy"));

But same result

Do you known if there is a specific way with Android to convert DateTime ? I really don’t understand because on unity editor my entire code works perfectly :confused:

Thanks for your tips.
Best Regards

Im having this issue as well was there ever a solution to this?
Edit: Try doing it as month/day/year that solved my issue.