This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
I'm having ArrayList collection. That ArrayListcontains Employee object. The Employee object contains Id, Name, Dept, DOJ, Address properties.
I have to print this ArrayList in a table format.
Could anyone please tell me how to display the print dialogue box and print the ArrayList values in table format?
What exactly do you mean by printing? On paper or on the command/terminal window?
What does toString() in Employee return?
Can you write a prettyPrintToString() or even a void prettyPrint() method in the Employee class? Then you could iterate through your List and call a pretty-printing method on each included Object.