Stock Portfolio Report Generator(SPRG) generates a spreadsheet report file based on stock portfolio data stored in an XML file. The generated spreadsheet report stores the number of shares of each stock, the purchase price per share, the current price per share, the current value of individual stock and all stock, and the gain gain/loss in percent and in dollars.


There is an example stock portfolio XML file in the download file. Use this to create your own portfolio XML file.


You can run the program with: java -jar sprg.jar sampleStockPortfolio.xml. A report spreadsheet labeled with the current date will then be created in the same folder.


The spreadsheet output is handled by Apache POI. The XML files are parsed with DOM for verification against a schema file and with StAX for actual data reading.


Stock Portfolio Report Generator(SPRG) is released under the GPL version 3 license. The source code is in the JAR file.


Version: 1.0

Last Updated: Nov 2, 2008

Release Date: Nov 2, 2008


Download: Stock Portfolio Report Generator