Or just advise how to add an image in the tooltip to display the image through the bend

  • And why do you need through the code-behind? Why not through binding? - VladD

1 answer 1

Found the solution, here:

ToolTip toolTip = new ToolTip(); StackPanel toolTipPanel = new StackPanel(); toolTipPanel.Children.Add(new TextBlock { Text = "Картинка", FontSize=23 }); toolTipPanel.Children.Add(new Image { Source= Image[i].Source }); toolTip.Content = toolTipPanel; button1.ToolTip = toolTip;