

For example, the following is valid:įor some reason, a single slash will also work (I guess internally Java will interpolate the extra // for the protocol specifier on files or perhaps there is something I don't understand in the URL specification which means that you don't need a // after the protocol).

On Windows a file representation of an absolute locator of a URI has three slashes after the file protocol.

If so, I'd recommend coding in Java and using JavaFX 2.x for this rather than JavaFX Script.
#FINALE NOTEPAD NOT PLAYING SOUND UPDATE#
UPDATE : By using file://e:/skin.mp3 it worked fine but left me with another exception : MediaException: MEDIA_INACCESSIBLE : eĪt .(Unknown Source) So can anyone tell me the reason of IllegalArgumentException Note: I'm just using notepad instead of any IDE. by including the jfxrt.jar file in classpath I'm compiling & running it correctly i.e. The exception which i'm getting is : : uri.getScheme() = null!Īt .locator.Locator.(Locator.java:217)Īt .(Media.java:364) MediaPlayer mediaPlayer = new MediaPlayer(hit) So my code is just the copy paste : import .*
