Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Message Resource FIle - Get Value

 
ankit maini
Greenhorn
Posts: 25
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using struts 1.1.
In my project i have one message-resources file called ApplicationResource.properties . Now i want to get the value of a key say my database password and username from this properties file in normal java class in my project. How can i do this. Please explain.

Thanks in Advance
 
ankit maini
Greenhorn
Posts: 25
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please reply as soon as possible.
 
rohit chavan
Ranch Hand
Posts: 132
Hibernate Java Oracle
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Hope you would have got the solution by now.

here is a code snippet which can be used for reading properties file in a web application.

 
ankit maini
Greenhorn
Posts: 25
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@rohit chavan

Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic