|
-
Apr 10th, 2006, 08:32 PM
#1
SelectNextControl in UserControl, not working? [2.0]
It seem so, when I tried it with the Textbox control it's working, but it doesn't seem to be when used in a UserControl inheriting a Textbox...
-
Apr 11th, 2006, 03:27 AM
#2
Re: SelectNextControl in UserControl, not working? [2.0]
Can you show us the code you're using? SelectNextControl is supposed to shift focus to the next control in the tab order. is that what you're trying to do? I'm not sure but I think it will also only select controls with TabStop set to True, or at leats by default. Does that sound like it would make any difference. Also, is this a UserControl or not? A UserControl inherits UserControl, while an inherited TextBox would be considered a custom control. If you have a UserControl that doesn't expose its constituent controls publicly then I'm not sure how SelectnextControl would behave. You'd think that it would still visit every control but I'm not sure.
-
Apr 11th, 2006, 03:42 AM
#3
Re: SelectNextControl in UserControl, not working? [2.0]
You may call it custom control since I just added a UserControl then replaced the inheritance with Textbox. I don't the code right now but its something like...
Code:
SelectNextControl(sender as TextBox, true, true, true, true)
Not sure how many true are there but I have set all the boolean parameters to true, with an ordinary textbox it's working but not with the custom control. And when I try Sendkeys("Tab") it's working though I don't want to use SendKeys, it's just weird...
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
|