Is there a method such that a user can click on the form itself, and in doing so remove focus from whatever object (textbox, combobox, etc) currently has it? Basically, can focus be uniformly removed from everything at once?
Setting the focus to the form itself does not work.
I thought about doing the old "hide a placeholder button behind another object" trick, but I'm really not a fan of that.
Thanks!
In VB6 a
PictureBoxcan get focus, even if it does not contain any control.In your case you can put a
PictureBoxwithTabStopfalse,BorderStyleset to 0,TabIndexset to 0 behind every other control but not containing any focusable control and stretch it toScaleWidthbyScaleHeightat run-time.You have to put the labels and any windowless control in this background
PictureBoxtoo.This way when the user clicks "on the form" the focus will "go away". With "no focus"
Tabkey will focus first control (the one withTabIndexset to 1).