This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I am currently in a data sturtures class(for java) at the college I attend. However, we have not covered a similar situation in any of the classes i have taken. I have a program that requires you to type in a Username and Password everytime the program is opened. I would like to write a little program in java to supply the Username and Password to the program when the program is opened. My question: How do I get the progrgam needing the Username and Password to open the file I have written? Or should the program I have written call the executable of the program that needs the Username and Password? I have never written something like this and could use any help offered.
I think you'll easily be able to store the information in a flat file --> a .properties file and have your program read in the information. You can find more information about .properties in this thread: Help with Properties file And in the API for java.util.Properties