Page 1 of 1

Localization and ChangePropertyAction

Posted: 16 Nov 2023, 19:06
by samc
I'm trying to change the text of a target using a ChangePropertyAction like this:
<b:ChangePropertyAction TargetName="Status" PropertyName="Text" Value="{noesis:Loc Text.FrontEnd.AddFriend.Label.InvalidFormat}"/>
However, this seems to always make the text into an empty string.

Is there another / valid way to do this?

thanks,
sam

Re: Localization and ChangePropertyAction

Posted: 17 Nov 2023, 19:38
by sfernandez
The current implementation of Loc extension only works for properties of FrameworkElements in the tree, because it uses the dictionary from the LocExtension.Resources inherited property. Could you please report this in our bugtracker, we want to analyze how we could add support for that.

In the meantime, could you try doing the following:
<TextBlock x:Name="txt" ... Tag="{noesis:Loc Text.FrontEnd.AddFriend.Label.InvalidFormat}"/>
...
    <b:ChangePropertyAction TargetName="Status" PropertyName="Text" Value="{Binding Tag, ElementName=txt}"/>

Re: Localization and ChangePropertyAction

Posted: 05 Apr 2024, 15:26
by David Jefferies
We have the same issue - has there been any progress adding support for this?

Re: Localization and ChangePropertyAction

Posted: 10 Apr 2024, 11:02
by sfernandez
I've created ticket #3226 to track development of this feature.
For the moment there's been no progress, sorry.

Can you use the proposed workaround or is not an option for you?