Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Set Focus

Posted on 1998-08-28
1
Medium Priority
?
168 Views
Last Modified: 2010-03-30
Just beginning a java course - How do you set focus in a TextField??  Please give details
0
Comment
Question by:cbugler
1 Comment
 
LVL 8

Accepted Solution

by:
diakov earned 200 total points
ID: 1222834
In the standart JDK 1.1, you must call the requestFocus() method of the component that you want to get the focus. The component must already be constructed and visible on the screen, when you do that. The visibility of a compoennt can be tested with isVisible() of the component.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.
Suggested Courses

971 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