1

I try to pass from simple binding to MultiBinding for CommandParameter but can not find out the syntax for "{Binding}" in the following example for the multibinding example below. Thanks a lot for any hint !

Regards, Fabianus

    <Button Content="Add subevent" HorizontalAlignment="Left" MinWidth="100" Command="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type Window}}, Path=DataContext.AddEvent}" CommandParameter="{Binding}" />

CommandParameter with MultiBinding:

                    <Button Content="Add subevent" HorizontalAlignment="Left" MinWidth="100" Command="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType={x:Type Window}}, Path=DataContext.AddEvent}" >
                    <Button.CommandParameter>
                        <MultiBinding Converter="{StaticResource searchFilterConverter}">
                            <Binding Path="" />
                            <Binding RelativeSource="{RelativeSource Mode=FindAncestor,AncestorType=Window}"  Path="DataContext.SelectedProduct"  />
                        </MultiBinding>
                    </Button.CommandParameter>
                </Button>
Fabianus
  • 633
  • 7
  • 16
  • `` is equivalent to `` or `{Binding}`. See here for details: https://msdn.microsoft.com/en-us/library/system.windows.data.binding.path(v=vs.110).aspx – Clemens Nov 26 '16 at 08:57
  • Hey @Clemens, thanks so much ! This is it ! Don't know how to mark your answer as "the" aswer. – Fabianus Nov 28 '16 at 12:10

0 Answers0