<TextBlock x:Name="txtContentMessage" Text="{Binding Text}" TextTrimming="CharacterEllipsis"
TextWrapping="Wrap" Foreground="{Binding Entities,Converter={StaticResource ChangedColorToUrlConverter}}" MaxLines="3" Grid.Row="1">
</TextBlock>
Now, It just pass data to object value. So I also want to pass to object parameter
现在,它只是将数据传递给对象值。所以我也想传递给object参数
- object value will be assigned by Entities.
- object parameter will be assigned by Text.
对象值将由实体分配。
对象参数将由Text指定。
1 个解决方案
#1
0
Use the ConverterParameter
binding property
使用ConverterParameter绑定属性
<TextBlock x:Name="txtContentMessage"
Text="{Binding Text}"
TextTrimming="CharacterEllipsis"
TextWrapping="Wrap"
Foreground="{Binding Entities, ConverterParameter='PUT TEXT HERE', Converter={StaticResource ChangedColorToUrlConverter}}"
MaxLines="3"
Grid.Row="1" />
#1
0
Use the ConverterParameter
binding property
使用ConverterParameter绑定属性
<TextBlock x:Name="txtContentMessage"
Text="{Binding Text}"
TextTrimming="CharacterEllipsis"
TextWrapping="Wrap"
Foreground="{Binding Entities, ConverterParameter='PUT TEXT HERE', Converter={StaticResource ChangedColorToUrlConverter}}"
MaxLines="3"
Grid.Row="1" />