Frank
  • Frank
  • Newbie Topic Starter
13 years ago
Hello,

Sometimes you'll have a problem with the focus in MS-Access-Apps when you are using igrid in subforms. The problem occurs only when you have an igrid on a sub-subform, activated it by clicking and then want to activate for example a normal Access-textbox on the subform or the mainform or any other form except the sub-subform. then the cursor blinks in the textbox you just clicked in, but you cant type text in it! the focus is still on the igrid, althougt the cursor blinks in the textbox. try to press the tab-key and you will see, that the next cell in the igrid is selected!

this problem is not a problem of igrid. it is a ms-access-activex-problem. you will get this not really funny behaviour when you use the listview or treeview or else.

But never mind! Here's the solution! :)
on the OnFocus-event of the textbox you want to activate, call the .setfocus-Event of a normal textbox on the sub-subform. Therefore you will have to put a normal textbox on the form where igrid is. ok, that's not really nice, but you can use this textbox for searching or filtering igrid for example. so it's not only a dummy-textbox.

You have to call the .setfocus-Event for each control you want to activate. that's really not nice too, but when you you use a igrid-class, the effort is not so high.

I hope this could help you!

Regards
Frank