I need some help with imagebrush it only works with absolute directories for example
<ImageBrush x:Name="bgimage" ImageSource="C:\Users\user\Desktop\MediaSampleWPF\MediaSampleWPF\obj\Debug\image.png" Stretch="Fill"/>
works fine but this
<ImageBrush x:Name="bgimage" ImageSource="image.png" Stretch="Fill"/>
gives me this error - if I replace image.png with notexist.png it gives me an error before compilation, but if I gut image.png it does not, meaning that the image actually exists
IOException: Cannot locate resource 'image.png'
the image is in every single directory of the solution , like, literally, i opened every folder in the project solution and i put image.png, but it still say that the image does not exist can someone help me?