This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I have my Netbeans Project after building of which creates a JAR file in the "dist" folder.
Now i want to read some settings stored in a "settings.ini" which i pasted in the same directory as the JAR file.
In my code i give directly, the name of the file to read from in the File Input stream. This does not work, and gives error saying cannot read from file, there is a path resolvnig problem...
What is the correct code notation to read from the file?
Yes this will work, bu i realised that i was making my code to commit suicide..
When you write the above code, it takes the base directory for the "Settings.ini" file to be in "projectHomeFolder/build/" directory, which is always deleted and re-created when you build you whole project.
As i have mentioned in the previous post, the solution was to paste the "Settings.ini" file in the "ProjectHomeFolder"