Nitin Surana wrote:I have already posted an example for something related to what you are trying to do. Here is the example link
Hope so this will help.
How I implement that code into netbeans? He dont alow me to edit generated code, so that is a bit problem, if i try to import something i got error on startup and then is bad code. :/
Edmund Petrof wrote:Ok what program to use? What you suggest?
Whit netbeans I make some nice application, wroking nicly just image is my problem. And I am not good at Hand code, Still a bit confused about bunch of stuff, but i got books and reading it daily, some books are for netbeans and other is for java, difrance is big. Like reading two difrante programing language. In netbeans is all about propertis and adding some words, in java all can be typed in the notpad.
So leave netbeans and go notpad? or some other program what you will recommend?
Digen Mahara wrote:use eclipse IDE the best for Java Programmers
Digen Mahara wrote:further your Image problem can be solved:
You can use a JPanel and use the paintComponent() method and drawImage() method to draw an image on the background and hard luck there is no way you can do this in Netbeans try it in Eclipse
Edmund Petrof wrote:
So basicly i need to drop netbeans generated code and code all by my self?
To view the generated code:
In the GUI Designer, click the Source tab.
Scroll down to the line that says Generated Code.
Click the plus sign (+) to the left of the Generated Code line to display the code that the GUI Designer has generated.
The key line is the following:
Since you have used the property editor for jLabel1's Icon property, the IDE has generated the setIcon method. The parameter of that method contains a call to the getResource() method on an anonymous inner class of ImageIcon. Notice that the generated path for the image corresponds with its location in the application's package structure.