How to set an Image as Background of a Grid in WPF

To set an image as background of a Grid, we can set an image as the Background of the Grid. The following code snippet sets the background of a Grid to an image. The code also sets the opacity of the image.


   <ImageBrush ImageSource="Flower.jpg" Opacity="0.3"/>