Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How jump to next control in Tab Order?

Posted on 2000-04-13
2
Medium Priority
?
293 Views
Last Modified: 2010-04-04
Hi!

I have an TEdit and a TButton. When I press the button I want the focus to change to the control placed directly after the TEdit in the Tab Order, no matter what kind of control that is. I've tried to send a WM_KEYDOWN message to the TEdit and to the form owning it, but it doesn't work. How can I do it?
0
Comment
Question by:Dippen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 17

Accepted Solution

by:
inthe earned 200 total points
ID: 2713664
Hi
set the tab order fpr your controls via the object inspector then on the buttons
OnKeyPress event do:

 If key=chr(13) //enter key
 then SendMessage(handle,WM_NEXTDLGCTL,0,0);

this will set focus to the next control in the order.
Regards Barry
0
 

Author Comment

by:Dippen
ID: 2714896
Thanks a bunch. Worked just fine!
0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Suggested Courses

618 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