9

I need to set the background of my System.Windows.Controls.Viewbox, but the property is missing.

How can I fix this problem?

Nick
  • 10,309
  • 21
  • 97
  • 201

2 Answers2

16

Put your viewbox inside a control that supports the background property:

<Border Background="Red">
   <ViewBox />
</Border>
Alberto
  • 15,626
  • 9
  • 43
  • 56
4

Put it in a Border and set its Background.

Nikhil Agrawal
  • 47,018
  • 22
  • 121
  • 208