WPF Image Dynamically changing Image source during runtime

前端 未结 6 1663
情深已故
情深已故 2020-12-09 02:59

I have a window with a title on it. When the user selects a choice from a drop down list, the title image can change. The problem is when the image loads, it\'s a blurred, s

6条回答
  •  春和景丽
    2020-12-09 03:31

    Like for me -> working is:

    string strUri2 = Directory.GetCurrentDirectory()+@"/Images/ok_progress.png"; image1.Source = new BitmapImage(new Uri(strUri2));

提交回复
热议问题