开发者

WPF image source

I have a wpf page defined in a runtime bound dll.

I am trying to place an image on the page from a folder in the main app.

The main as is called "Panel". I am doing this:

    <Image Source="/Panel;component/Images/LRL.bmp" Height="46" HorizontalAlignment="Left" Margin="306,90,0,0" Name="imgLRL" Stretch="Fill" VerticalAlignment="Top" Width="127"  />

While the image resolves at design time, it is blank when run. Any su开发者_如何学JAVAggestions?

I just tried, per suggestion:

    <Image Height="46" HorizontalAlignment="Left" Margin="306,90,0,0" Name="imgLRL" Stretch="Fill" VerticalAlignment="Top" Width="127" Source="pack://application:,,,/Panel;component/Images/LRL.bmp" />

but same thing


When I added an images, I have a subfolder called images and I do something like this

<Image Source="Images/someimage.bmp" />

Maybe this is what you need to.


Snoop helped me resolve this. Thanks for the turn on to a new utility for me.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜