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

why should we get the following error ? Exception in main method NoClassDefFoundError:classname could anyone give the detail clarification on how java compiler can look for .class file?

2 Answers  


Can we write class inside a class in java?

0 Answers  


Explain serialization and deserialization in java?

0 Answers  


Explain about static imports in java?

0 Answers  


Why does java doesnt suuport unsigned values?

0 Answers   ABC,






Is finalize() similar to a destructor?

0 Answers  


Is a string literal?

0 Answers  


What is meant by stack and queue?

0 Answers   GrapeCity,


What is the difference between stringbuffer and stringbuilder class?

0 Answers  


Is an array a vector?

0 Answers  


What is java english?

0 Answers  


In which language JVM (Java Virtual Machine) is implemented

5 Answers  


Categories