This content has been marked as final. Show 4 replies
Have a look at the [Properties API Doco|http://java.sun.com/javase/6/docs/api/java/util/Properties.html], you decide it it's useful.
"Just a text file" gives us zero idea of the format... you're going to need to be much more forthcoming with the nitty gritty in order to recieve any real help here... While can read minds, we try to refrain from doing so, as we've discovered that is seriously upsets the management.
Edited by: corlettk on 26/08/2008 22:41 - Ooops!
Here is an example of what the .txt file looks like, and it is in notepad:
Current configuration : 24336 bytes
no service pad
service timestamps debug datetime localtime
service timestamps log datetime localtime
no logging console
enable secret 5 **%3920$1rizoekw/lvslhe$** - what I need to replace
And it goes on and on. So what I had so far was to actually open the file, bring it in line by line and search each line for the phrases to look for, which works but I just don't know how to replace the text after the phrase, such as the info after the 5 in the example above.