Textbox focus problems

A

Ayende Rahien

I've a form that contains a panel that contains a text box, but I can't
get the default focus to be on the text box.
I want to open this form and start typing, but it doesn't work.
I tried settting the tab index, and I tryed the textbox.Select() &
textbox.Focus() on the form's Load event, but it didn't work.
Anyone knows why?
What happens is that the focus is just one tab away from it, and it's
driving me nuts.
 
W

webmasta

Give textbox index of 0 and tabstop = true

~webmasta



| I've a form that contains a panel that contains a text box, but I can't
| get the default focus to be on the text box.
| I want to open this form and start typing, but it doesn't work.
| I tried settting the tab index, and I tryed the textbox.Select() &
| textbox.Focus() on the form's Load event, but it didn't work.
| Anyone knows why?
| What happens is that the focus is just one tab away from it, and it's
| driving me nuts.
|
 
W

webmasta

We could be going back and forth on this to nail down the issue ... best attach pertinent code.

~webmasta.


| It already has those, not working.
|
 
A

Ayende Rahien

Sorry, I managed to find that the problem is somewhere in WeifenLuo
DockPanel.
Apperantly the DockPane is stealing the focus, but I can't quite see
/how/ it does it. Since it do it only in a very spesific way. And I
can't seem to repreduce it with less code.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top