EXAMPLE:
Expand|Select|Wrap|Line Numbers
- private void ChangeIcon()
- {
- if(NotifyIcon.Icon == Properties.Resources.Icon1) NotifyIcon.Icon = Properties.Resources.Icon2;
- else NotifyIcon.Icon = Properties.Resources.Icon1;
- }
So it's always stuck on the first if, so I'm wondering how I could get it to compare using the resource name or something else so it knows what Icon it's using.
Currently I'm just using a counter and changing the number each time.
EXAMPLE:
Expand|Select|Wrap|Line Numbers
- private int Number = 1;
- private void ChangeIcon()
- {
- if(Number == 1) { NotifyIcon.Icon = Properties.Resources.Icon2; Number = 2; }
- else { NotifyIcon.Icon = Properties.Resources.Icon1; Number = 1; }
- }
All help is appreciated.