DateTimePicker lose leading 0 in milliseconds when lose focus.
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 58/100
Research direction
Start in ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/DateTimeUpDown/Implementation/DateTimeParser.cs, at ComputeDateTimeString and its millisecondsPart calculation. Reproduce the focus-loss case with 28.04.2025 16:26:16.080 and inspect the resulting value. Done means the leading zero is preserved after the DateTimePicker loses focus.
Written by the indexing model from the issue text.
Description
Error location
DateTimeParser.cs
private static string ComputeDateTimeString( string dateTime, string format, DateTime currentDate, CultureInfo cultureInfo, bool autoClipTimeParts )
//Has error here.
string millisecondsPart = currentDate.Millisecond.ToString();
Case
If picker has dateTime value like this '28.04.2025 16:26:16.080'
millisecondsPart = "80";
We have lost leading 0.
in the end we have a result like this '28.04.2025 16:26:16.80'
'28.04.2025 16:26:16.80' == '28.04.2025 16:26:16.800'
'28.04.2025 16:26:16.80' != '28.04.2025 16:26:16.080'
Summary
Control lost focus and value changed.
- Dominant language
- C#
- Stars
- 4.2k
- Forks
- 912
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from xceedsoftware/wpftoolkit
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
xceedsoftware/wpftoolkit#1808 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 48/100
xceedsoftware/wpftoolkit#1807 · 2 comments ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
xceedsoftware/wpftoolkit#1806 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 45/100
xceedsoftware/wpftoolkit#1804 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
xceedsoftware/wpftoolkit#1802 · 3 comments ·
All issues in xceedsoftware/wpftoolkit
Similar issues
-
type/automation type/tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
t/bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
ci-failure-cause test-failure
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
area:auth FE mvp P3
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
klasolsson81/jobbliggaren#1788 ·