Results 1 to 2 of 2
  1. #1
    mayank04 is offline Member
    Join Date
    Apr 2011
    Posts
    1
    Rep Power
    0

    Smile Need help in removing error in media player

    Hi all,

    I am want to make a media player. In my code there is no error at compile time but at run time it showing an error which is given below:


    Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
    at javax.swing.ImageIcon.<init>(ImageIcon.java:167)
    at uk.co.caprica.vlcj.test.basic.TestPlayer.<init>(Te stPlayer.java:165)
    at uk.co.caprica.vlcj.test.basic.TestPlayer$1.run(Tes tPlayer.java:103)
    at java.awt.event.InvocationEvent.dispatch(Invocation Event.java:209)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.j ava:642)
    at java.awt.EventQueue.access$000(EventQueue.java:85)
    at java.awt.EventQueue$1.run(EventQueue.java:603)
    at java.awt.EventQueue$1.run(EventQueue.java:601)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.AccessControlContext$1.doIntersectio nPrivilege(AccessControlContext.java:87)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java: 612)
    at java.awt.EventDispatchThread.pumpOneEventForFilter s(EventDispatchThread.java:269)
    at java.awt.EventDispatchThread.pumpEventsForFilter(E ventDispatchThread.java:184)
    at java.awt.EventDispatchThread.pumpEventsForHierarch y(EventDispatchThread.java:174)
    at java.awt.EventDispatchThread.pumpEvents(EventDispa tchThread.java:169)
    at java.awt.EventDispatchThread.pumpEvents(EventDispa tchThread.java:161)
    at java.awt.EventDispatchThread.run(EventDispatchThre ad.java:122)


    Please help me in running these code.Its very urgent.

    Thanks in advance!!!

  2. #2
    ozzyman's Avatar
    ozzyman is offline Senior Member
    Join Date
    Mar 2011
    Location
    London, UK
    Posts
    797
    Blog Entries
    2
    Rep Power
    4

    Default

    The image file doesn't exist, couldn't be found and/or the path specified was done so incorrectly.

    //ImageIcon.java:166-168
    Java Code:
        public ImageIcon (URL location) {
            this(location, location.toExternalForm());
        }

Similar Threads

  1. Java media player with subtitles with JVLC or JMF
    By foulkes in forum Advanced Java
    Replies: 0
    Last Post: 02-08-2011, 04:22 PM
  2. JMF: disable media info on a JMF Player
    By MarcioVilanova in forum Advanced Java
    Replies: 0
    Last Post: 08-11-2010, 08:16 PM
  3. javax.media.Player and JMenu problem
    By nowy in forum AWT / Swing
    Replies: 2
    Last Post: 11-10-2009, 11:49 AM
  4. Replies: 0
    Last Post: 11-04-2009, 09:09 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •