+ 13

How to set value using properties file ?

I did it set and get but when I set a key other key is deleted. ***Properties File*** name=pedro number=2 I used this method.... prop.setProperty ("name", "test"); It write very well but number key is deleted. I need to set all keys: prop.setProperty ("name", "test"); prop.setProperty ("number", "123"); I wanna set only one key.

14th Aug 2019, 11:37 PM
Pedro H.J
Pedro H.J - avatar
3 Antworten
15th Aug 2019, 1:24 PM
Gordon
Gordon - avatar
+ 6
Paolo De Nictolis Thank you for feedback. I will try this. I am using. INI file now but I wanna try properties as well.
15th Aug 2019, 8:56 PM
Pedro H.J
Pedro H.J - avatar