View Issue Details

IDProjectCategoryView StatusLast Update
0004396NoesisGUIStudiopublic2025-10-06 11:53
ReporterAlexLashkevich Assigned Tosfernandez  
PrioritynormalSeverityminor 
Status feedbackResolutionopen 
Product VersionStudio_Beta 
Target VersionStudio_Beta 
Summary0004396: bug in StringFormat
Description

hello,
there is a bug in StringFormat:
Text="{Binding Path=Mileage, StringFormat={}{0:D6} KM}" is not working in noesis studio, but works in the game

PlatformWindows

Activities

AlexLashkevich

AlexLashkevich

2025-10-01 16:49

reporter   ~0011071

StringFormat_bug.jpg (122,455 bytes)   
StringFormat_bug.jpg (122,455 bytes)   
sfernandez

sfernandez

2025-10-02 16:27

manager   ~0011073

Just to confirm:

  • I guess the attached DataContext exposes a "Mileage" property
  • Is the binding working if you remove the StringFormat?
AlexLashkevich

AlexLashkevich

2025-10-03 14:25

reporter   ~0011077

yes, binding is correct and also some other formats, like 0:N6 work well

sfernandez

sfernandez

2025-10-06 11:53

manager   ~0011083

I've checked the specification and it turns out that D specifier only works with integer values. And the issue is all the number properties in the Data structures are float values, so the string format fails even if there are no decimals.

As a workaround you can use the following custom format:
Text="{Binding Path=Mileage, StringFormat={}{0:000000} KM}"

Could you try that?

Issue History

Date Modified Username Field Change
2025-10-01 16:48 AlexLashkevich New Issue
2025-10-01 16:49 AlexLashkevich Note Added: 0011071
2025-10-01 16:49 AlexLashkevich File Added: StringFormat_bug.jpg
2025-10-02 16:25 sfernandez Assigned To => sfernandez
2025-10-02 16:25 sfernandez Status new => assigned
2025-10-02 16:25 sfernandez Target Version => Studio_Beta
2025-10-02 16:27 sfernandez Status assigned => feedback
2025-10-02 16:27 sfernandez Note Added: 0011073
2025-10-03 14:25 AlexLashkevich Note Added: 0011077
2025-10-03 14:25 AlexLashkevich Status feedback => assigned
2025-10-06 11:53 sfernandez Status assigned => feedback
2025-10-06 11:53 sfernandez Note Added: 0011083