I'm pretty new to VBA and may be trying to bite off more than I can chew. However, I need to create a procedure that will look at a list stock trades made, then create a .csv file summarizing all the trades. Below is an example:
<tbody>
</tbody>
The top shows the trades made in a certain account. The bottom shows a summary of those trades. EH is the header, EA is a listing of each account and the qty, and ET the trailer showing how many accounts and the total. Each unique Security (buys and sells) will have at least these three. EH, EA, and ET. So, GE stock was bought (B for buy) in two accounts - With a total of 260 shares. BA was bought in 1 account for 50 shares. BA was sold (S for sold) in one account for 50 shares, etc.
I'm wanting help thinking about how to break this out into steps, not so much the code for each step. How would you think about the steps for completing this? I'm using Excel 2010.
Please ask questions to clarify - I'm sure I left a bunch of info out.
Thanks!
Account | Action | Ticker | Shares | Account Name | ||
1234-5678 | B | ge | 10 | John Smith | ||
1234-5678 | B | ba | 50 | John Smith | ||
1234-5678 | B | wmt | 75 | John Smith | ||
1234-5678 | B | amzn | 125 | John Smith | ||
1234-5678 | B | goog | 50 | John Smith | ||
1234-5678 | B | aaple | 75 | John Smith | ||
1234-5678 | S | xom | 200 | John Smith | ||
1111-2222 | S | intc | 600 | William and Mary Baker | ||
1111-2222 | S | ge | 250 | William and Mary Baker | ||
1111-2222 | S | ba | 50 | William and Mary Baker | ||
1111-2222 | B | wmt | 125 | William and Mary Baker | ||
1111-2222 | B | amzn | 25 | William and Mary Baker | ||
1111-2222 | B | goog | 200 | William and Mary Baker | ||
EH | 20150612 | 99999999 | B | ge | 1 | 20150612 |
EA | 12345678 | 10 | ||||
EA | 11112222 | 250 | ||||
ET | 2 | 260 | ||||
EH | 20150612 | 99999999 | B | ba | 1 | 20150612 |
EA | 12345678 | 50 | ||||
ET | 1 | 50 | ||||
EH | 20150612 | 99999999 | S | ba | 1 | 20150612 |
EA | 11112222 | 50 | ||||
ET | 1 | 50 | ||||
<tbody>
</tbody>
The top shows the trades made in a certain account. The bottom shows a summary of those trades. EH is the header, EA is a listing of each account and the qty, and ET the trailer showing how many accounts and the total. Each unique Security (buys and sells) will have at least these three. EH, EA, and ET. So, GE stock was bought (B for buy) in two accounts - With a total of 260 shares. BA was bought in 1 account for 50 shares. BA was sold (S for sold) in one account for 50 shares, etc.
I'm wanting help thinking about how to break this out into steps, not so much the code for each step. How would you think about the steps for completing this? I'm using Excel 2010.
Please ask questions to clarify - I'm sure I left a bunch of info out.
Thanks!