ghuughes93
New Member
- Joined
- Aug 6, 2014
- Messages
- 10
Hi everybody. New to this forum. 
I just have a really quick question about Class Modules. The only problem is I am clueless with Excel and have a deadline for tomorrow to do this exercise for.
I have about 5000 rows of data like this:
[TABLE="width: 192"]
<colgroup><col width="64" span="3" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]Direction[/TD]
[TD="width: 64"]Quantity[/TD]
[TD="width: 64"]Price[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]400[/TD]
[TD="align: right"]12.75[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]19.53[/TD]
[/TR]
[TR]
[TD]S[/TD]
[TD="align: right"]900[/TD]
[TD="align: right"]38.34[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]9.56
[/TD]
[/TR]
</tbody>[/TABLE]
B = buy and S = sell. I need to work out the total value. If the direction is buy (i.e. you're spending money) it should be a minus figure. If it's sell (i.e. you're gaining money) it should be a positive figure.
The cash associated with every row is Quantity*Price. So for the first one it's -(400*12.75) and for the third its 900*9.56. I need to output the total net cash (sum of the cash) from the trades in the spreadsheet in a Message Box.
I can't tell you how stuck I am right now and would greatly greatly appreciate any help.
Thank you in advance if anyoncan give me any direction!

I just have a really quick question about Class Modules. The only problem is I am clueless with Excel and have a deadline for tomorrow to do this exercise for.
I have about 5000 rows of data like this:
[TABLE="width: 192"]
<colgroup><col width="64" span="3" style="width:48pt"> </colgroup><tbody>[TR]
[TD="width: 64"]Direction[/TD]
[TD="width: 64"]Quantity[/TD]
[TD="width: 64"]Price[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]400[/TD]
[TD="align: right"]12.75[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]19.53[/TD]
[/TR]
[TR]
[TD]S[/TD]
[TD="align: right"]900[/TD]
[TD="align: right"]38.34[/TD]
[/TR]
[TR]
[TD]B[/TD]
[TD="align: right"]100[/TD]
[TD="align: right"]9.56
[/TD]
[/TR]
</tbody>[/TABLE]
B = buy and S = sell. I need to work out the total value. If the direction is buy (i.e. you're spending money) it should be a minus figure. If it's sell (i.e. you're gaining money) it should be a positive figure.
The cash associated with every row is Quantity*Price. So for the first one it's -(400*12.75) and for the third its 900*9.56. I need to output the total net cash (sum of the cash) from the trades in the spreadsheet in a Message Box.
I can't tell you how stuck I am right now and would greatly greatly appreciate any help.
Thank you in advance if anyoncan give me any direction!