I'm using WPF and I want to use NotifyIcon
from WinForms. My icon image is located in <project_folder>/Resources/icon.ico
. It has Build action
set to Resource
. But this code: this.ni.Icon = new System.Drawing.Icon("pack://application:,,,/Resources/icon.ico");
throws me an exception: The given path's format is not supported.
What's the problem? How can I solve it?