programmatically setting radio-button to selected is not firing the actionPerformed event

Posted on 2004-09-10
Last Modified: 2008-02-26

as question title suggests i want to programmatically select a radio-button, but i want it also to fire the radio-buttons actionListener event, how do i do this??
Question by:cathalmchale
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
  • 3
  • 2
LVL 86

Expert Comment

ID: 12028531
You'll have to either call actionPerformed directly or post an event with EventQueue.postEvent(...)

Author Comment

ID: 12028939
ah ok, no problem that works!!

is there a way of doing this:
the main frame has a tabbed pane - so each tab is a panel.  when a tab is clicked then panelMe becomes visible.
can panelMe listen for an event "when i become visible to the user then do something" ??
LVL 86

Assisted Solution

CEHJ earned 25 total points
ID: 12028988
Add a ChangeListener and then do that something if it's the right panel selected:
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 92

Accepted Solution

objects earned 25 total points
ID: 12031837
LVL 86

Expert Comment

ID: 12064885
LVL 92

Expert Comment

ID: 12071463
thanks mate :)

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Configure a Bean in an XML file 4 49
What browser will run Java? 7 128
American Express @Work site and Java 4 68
Find out all repos that a user is most active on Github 1 33
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
This video teaches viewers about errors in exception handling.
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.

726 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