I have tried and tried to make an applet in notepad that simply has three buttons(clear,red,black) and then have a drawing area. I cannot get it quite right. The suggestions I have got gotten and examples are too vague to be of any help. Can I create an applet in NetBeans? I only want one .java file. Or do I have to have all those other files that are created too? Im wanting to design the GUI in it and then read it to see how it did it. I think I can use this to create my own examples since I have not seen any good ones.
Help, Help Contents, Search, and then type in 'applet', one of the very first help topics explains exactly how to do it (Creating an Applet). In order to use the gui builder, again go to Help, Help Contents, Search, and type in 'gui builder'. The third or fourth topic down will send you to another link called 'Working With the GUI Builder, and 'Designing Java GUI with GUI Builder'. Those are about as step by step as one can get.
Usually when things are not working like one expects, there are error messages thrown, or something happens that can be described. "I can not get it right" could mean that the GUI is not displaying at all, the buttons are not lining up, nothing happens when the buttons are clicked, there are no labels on the buttons, the background color is wrong, etc. We have no idea what you are seeing.
do I have to have all those other files that are created too
I have a contentPane and I can draw lines on it using my mouse, I have three buttons, Clear, Red, Black(they change line color). I was told to clear a screen I should draw a rectangle the size of the applet and fill it with the same color as my background color. This takes away my buttons unti lI mouse over them again. Someone suggested making a Panel off the the content Pane and did not give any more info on how to do that.
The other issus is
if I dont clear out the coordinates after drawing a line then the last line drawn becomes the new color I selected. Id I do clear out the coordinates then if I draw lines too fast some of them start at (0,0). So being able to step through the code and seeing what its doing will help since I have it written in Notepad right now. My main trouble though is understanding how to code the GUI in notepad and how everything works as far as the GUI is concerned. I think using NetBeans I can look at the generated code and see what its doing, kinda like making my own examples.
All those other files refer to Build.xml mainfest.mf then the nbproject folder and everything else that is created.
I have the applet created, but how do I design the GUI for it? I right clicked on the Project name and did, new, JFrame Form and it showed me the GUI editor, but it also created a template for a java progam, not an applet. I looked through the help and that is how it said to do it. Will I have to make it a program and then covert it over to an applet later if I want to use the GUI editor on my applet?
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com