ADDING A ICON IMAGE TO YOUR JAVA PROGRAMME -NETBEANS

Screenshot (97)

Follow these Steps :

    • Open Net-Beans

    • Create a new project

    • Create a new JFrame Form
create New JFram form create New JFram form
  • Design your Frame

  • Go to the Source

  • Right after the MainFrame constructor let’s create a method  call loadFrameIcon

  • Add these code lines
loadFrameicon() loadFrameicon()
  • Call the method loadFrameIcon

  • Run the project once to create the classes,You will get errors just ignore them

  • Here desk32.gif is the image name

  • You need to add the image to relevant location

  • Go to netbeans projects folder located in MyDocuments -Open your project File

  • Eg:I named my project as Sample so I opened sample folder in netbeans project

  • Then goto built,then to classes then their will be folder as your project name go inside it

  • Create a new Folder called images inside that folder and past the relevant image.
Create the Folder Create the Folder
  • Watch this in full screen please
https://www.youtube.com/watch?v=Audvmzz2TOs