Solved

How jump to next control in Tab Order?

Posted on 2000-04-13
2
285 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
2 Comments
 
LVL 17

Accepted Solution

by:
inthe earned 50 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

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delphi Form ownership 4 86
DBGrid or StringGrid ? 6 88
Drag & Drop... Data from one grid to another 2 11
can i put an image from resource into image tag ? 6 24
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…
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

786 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