Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Programmatically selecting the tab page to get focus

Posted on 2007-08-08
4
Medium Priority
?
2,097 Views
Last Modified: 2013-12-26
I need to move the focus to specific controls on specific tab pages within tabcontrol (standard CF tab control). For example I need to move to a datetimepicker (dtSchedule) on tabpage 2 from tabpage 4.

I seem to remember it had something to do with the tab index but don't remember the syntax. Thanks,

JackW9653
0
Comment
Question by:JackW9653
  • 2
  • 2
4 Comments
 
LVL 38

Expert Comment

by:PaulHews
ID: 19655570
Is this .NET or VB6... What is the CF tab control?  




0
 

Author Comment

by:JackW9653
ID: 19655736
VB.Net (Visual Studio 2005) - CF = Compact Framework. This is a Mobile 5.0 app.
0
 
LVL 38

Accepted Solution

by:
PaulHews earned 2000 total points
ID: 19656659
Should be like:

TabControl.SelectedIndex = Index  'Zero based
dtSchedule.Focus()
0
 

Author Comment

by:JackW9653
ID: 19658817
Thanks Paul,worked well.
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article we will discuss all things related to StageFright bug, the most vulnerable bug of android devices.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Suggested Courses
Course of the Month12 days, 2 hours left to enroll

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question