+ 1

Applet in java

We need to use an applet tag like <applet code="classname" width="200" height="200"></applet> if we use notepad & cmd to compile and run. But if we use IDE like netbeans or IntelliJ Idea,how can we specify size of the applet.

9th Jul 2018, 7:49 AM
harshit
harshit - avatar
1 ответ
+ 9
A quick solution: public void init() { setSize(240, 320); } Width is now 240 and height is 320. EDIT: You can set custom width and height in IntelliJ IDEA in the Run/Debug configuration dialogue. https://www.jetbrains.com/help/idea/run-debug-configuration-applet.html [For Netbeans IDE] If that solution doesn't work, or if you want to automate the process, you might go through this link: https://stackoverflow.com/a/1064897
9th Jul 2018, 8:05 AM
Dev
Dev - avatar