|
-
Jan 18th, 2008, 07:08 AM
#1
Thread Starter
Frenzied Member
Focus problem
I have a treeview and then an array of pictureboxes.
On picHolder(1) I have an array of textboxes.
In the treeview click code I have the following:
Code:
picHolder(1).ZOrder 0
txtAdd(0).SetFocus
cmbGrade.ListIndex = 0
optGender(0).Value = True
When txtAdd(0) has focus the backcolor changes to a light grey colour.
When txtAdd(0) loses focus the backcolor changes to white.
When I click on the treeview this code fires, the txtAdd(0) backcolor changes, but the cursor is not in the textbox.
If I hit the tab key all the textboxes loses focus, but the backcolor stays grey, it goes somewhere, and the second time I hit the tab key the focus is back on txtAdd(0) with the cursor, and then goes through the textboxes as expected.
The treeview tabindex = 0 and the txtAdd(0) tabindex = 1
Anybody got any suggestions why?
Also, why I am on it, are pictureboxes the best way to do this, show different sets of controls?
I think I read somewhere that controls inside of frames have a problem with the resize code. Is this correct?
Thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|