C
C#11mo ago
DoctorShammy

NotifyIcon reference in Wpf doesn't work

I am having problems with this code. I think I have the correct usings but the NotifyIcon is still not being recognized. Does anyone know why?
No description
11 Replies
sibber
sibber11mo ago
yeah wpf doesnt have that you need a 3rd party package
sibber
sibber11mo ago
Hardcodet.NotifyIcon.Wpf 1.1.0
This is an implementation of a NotifyIcon (aka system tray icon or taskbar icon) for the WPF platform. It does not just rely on the Windows Forms NotifyIcon component, but is a purely independent control which leverages several features of the WPF framework in order to display rich tooltips, popups, context menus, and balloon messages. It can be...
sibber
sibber11mo ago
ive used this one before
Mayor McCheese
Mayor McCheese11mo ago
There used to be a way to use the windows forms notify iirc I'm going to try that library you mention though, as using the old notify icon was ass
sibber
sibber11mo ago
yeah you can reference winforms but its overkill to reference an entire framework just for that
DoctorShammy
DoctorShammyOP11mo ago
ok awesome thank you for clarifying! I seem to be now getting an error for : Application how can I fix that? public partial class App : Application(error here) { private NotifyIcon notifyIcon; }
sibber
sibber11mo ago
what's the error
DoctorShammy
DoctorShammyOP11mo ago
sorry im just tired, forgot to put in the using
DoctorShammy
DoctorShammyOP11mo ago
Do you know what reference ContextMenu needs?
No description
Buddy
Buddy11mo ago
Read docs
sibber
sibber11mo ago
ctrl + .
Want results from more Discord servers?
Add your server