Click here to Skip to main content
15,897,273 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello everybody,

my current problem is:
I'm working on a java application which needs an ini-file (given its path as parameter) to run the application. In that ini-file, there is another path, which is very important for this application. How can I use this file without multiple slashes?

I'm glad about any answers.
Posted
Comments
Richard MacCutchan 12-Sep-11 4:19am    
Does ./filename not work?
TorstenH. 12-Sep-11 4:24am    
can't work, a backslash starts the escape-sequence.
Richard MacCutchan 12-Sep-11 5:03am    
OK then a forward slash, it's always worth a try.
epanjohura 12-Sep-11 4:48am    
Np, that doesn't work :(
Richard MacCutchan 12-Sep-11 5:05am    
What does not work? Why not show exactly what you have tried and explain clearly what you are trying to achieve and why it does not work.

If you're working with that String value you should

- make it a setting not editable for customers
- take care of the slashes. Backslashes do not work - using slahes ("/") is sometimes a better option. Otherwise double the backslashes (String.replaceAll())
 
Share this answer
 
v2
Comments
epanjohura 12-Sep-11 4:52am    
I tried it without double slashes but that doesn't work at all.. It must be an absolute path with double slashes, but that's not what I wanted.

Are there any settings in Eclipse? Otherwise I try it with programming it by my self...
 
Share this answer
 

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