How can i add a button in applet in java ???

Answers were Sorted based on User's Feedback



How can i add a button in applet in java ???..

Answer / s.krishna veni

buttons should be declared..
coding to add a button :
Button b1;
b1=new Button("ok");
add(b1);

and after declaring the button..,we should add it to the
applet window..
so that a button is added at run time..

Is This Answer Correct ?    3 Yes 0 No

How can i add a button in applet in java ???..

Answer / giridhar gangapatnam

Button b1=new Button("OK");
add(b1);

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

what is the output ? Math.floor(-2.1) a)2 b)-2 c)-3.0 d)0

4 Answers   Accenture,


What is "finally" keyword?

10 Answers  


What are the different tags provided in jstl?

0 Answers  


What is natural ordering in java?

0 Answers  


What is connection class in java?

0 Answers  


What is private public protected in java?

0 Answers  


Does java runtime require a license?

0 Answers  


How do you create a null object?

0 Answers  


why java uses class level type casting ?

0 Answers  


which class to use when concatenating strings in a loop.

3 Answers   IBM,


What is difference between fail-fast and fail-safe?

0 Answers  


What is the format specifier?

0 Answers  


Categories