A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
.ToShortDateString() uses the current culture unless passed. Android has a different default culture. The bug is in your code.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
So since debugging with Android and the emulator is so horrible I am now debugging on windows (had to change init a bit as it reads a file). Now this way of doing things works well. Then KABANG!! I have an endpoint that need a date string in the format 2024-02-20 (example) so I was using theDatePicker.Date.Date.ToShortDateString() and this worked will in windows. So I would get the following string in windows - 2024-02-20 Now after the code works I switch to Android and run it to test on Android and well it doesn't the string is - 2/20/2024 which causes the endpoint to fail. Perhaps the ads for Maui should read "the majority of the time it works on all platforms". So as I have said on prior posts I spend as much time debugging Maui and VS as I do my app. Why????
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
Answer accepted by question author
.ToShortDateString() uses the current culture unless passed. Android has a different default culture. The bug is in your code.