Q:

Java Applet - RadioButton Demo

0

This Program is used to Demonstrate the Applet RadioButton Component Program.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

import java.awt.*; 
import java.applet.*; 
import java.awt.event.*; 

public class rad1 extends Applet 
{ 
CheckboxGroup cg; 
Checkbox r1,r2; 


public void init() 
{ 
cg=new CheckboxGroup(); 

r1=new Checkbox("Male",cg,false); 
r2=new Checkbox("Female",cg,false); 


add(r1); 
add(r2); 
} 
} 


/* <body> 
<applet code = "rad1.class" height = 250 width = 250> 
</applet> 
</body> */

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now