Click here to Skip to main content
15,891,431 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:

Hello friends...

I have developed a JAR file that contains the sample audiotesting code. The JAR file contains a folder called wavfile which holds the wavefiles of the project. I used to get the current dir of the JAR by adding the follwing code into it:

System.getProperties("User.dir"+"\\WavFile");

But when I try to run this file in another Windows system it is not working.

The code searches for the wavefile where the jar has been loaded

For example: If I load my JAR file in C:\\ then the code searches for the wavefile folder in C:\\ and not inside the JAR file and throws me the error

File not found:C:\\WavFile\\English\\mysound.wav

Any ideas for me .....

Posted
Updated 25-Nov-09 4:42am
v2

1 solution

You need to extract the file first. This site should help you with getting the file out of the archive.
 
Share this answer
 
v4

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900