WPF GifBitmapDecoder Uri相对路径问题

时间:2010-10-01 06:05:18

标签: wpf image path uri animated-gif

我正在尝试将Uri对象的uriString设置为在GifBitmapDecoder中使用的相对路径。

在运行时,我收到以下错误:

  

Invalid URI: The format of the URI could not be determined.

我的相对路径遵循以下格式:

  

/TestApplication;component/Images/Busy.gif

如果我使用图像的绝对路径,那么一切都很完美!

任何帮助将不胜感激!

1 个答案:

答案 0 :(得分:2)

找到答案:

http://msdn.microsoft.com/en-us/library/aa970069.aspx

我错过了以下内容: pack:// application:,,, 在我的相对路径前面。

相关问题