From 2652bb277dce956224cc18b3396b361c9ddda0c1 Mon Sep 17 00:00:00 2001 From: Jonathan Jenne Date: Mon, 28 Feb 2022 14:37:50 +0100 Subject: [PATCH] GlobalIndexer: Fix date picker flipping day and months --- GUIs.GlobalIndexer/ControlCreator.vb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/GUIs.GlobalIndexer/ControlCreator.vb b/GUIs.GlobalIndexer/ControlCreator.vb index 54c57eb4..61a4d2ab 100644 --- a/GUIs.GlobalIndexer/ControlCreator.vb +++ b/GUIs.GlobalIndexer/ControlCreator.vb @@ -76,7 +76,11 @@ Public Class ControlCreator If pDefaultValue.ToUpper = PLACEHOLDER_NULL Then oPicker.EditValue = Nothing ElseIf pDefaultValue IsNot Nothing Then - oPicker.EditValue = pDefaultValue + Dim oDateValue As Date = Nothing + + If Date.TryParse(pDefaultValue, oDateValue) Then + oPicker.EditValue = oDateValue + End If End If oPicker.Properties.AppearanceFocused.BackColor = HightlightColor