You're going to have to do a global hook. When you "minimize" the form, it no longer has the focus.
Try
SetWindowsHookEx
with whatever message represents your joystick button message is. An example can be found at
How to set a Windows hook in Visual C# .NET[
^]
But from what I can tell, global hooks generally are not supported by .Net. From the above webpage:
"Except for the WH_KEYBOARD_LL low-level hook and the WH_MOUSE_LL low-level hook, you cannot implement global hooks in the Microsoft .NET Framework."