in a C# winform, I have an app that has a 'silent mode' in it, in that mode it gets minimized and hidden from the task bar, AKA:
this.WindowState = FormWindowState.Minimized;
this.ShowInTaskbar = false;
But at a certain point, I want the main window of the program to show up again by pressing a certain key combo on the keyboard, like for example Alt+Ctrl+Shift+S But i just don't know how to do that.
The way i got around this was totally different, if the user wanna gets the window back, he'd have to create a file called 'SilentMode.OFF' in a specific directory. doing so will get the window back. I managed to do this by a timer in my app, the timer checks to see if that file is created in that dir, if so, show the window. Not that's not really a pro way to do things.
My Q: how can I communicate with a minimized window ? how can i send it and make it respond to the keys that i want it to respond to ?
I tried some of the events' like the Leave event and some other, but didn't really work.
Any tips would be of great help, Thank you.