I am having an issue figuring out the a formula that will look for duplicate stock symbols as they are entered BUT are no more than 30 days old AND the previous transaction was sold at a loss. (Of course, I need to apply this to open entries already in the spreadsheet.)
If this criteria is true, then (ideally) I'd like to have the following happen:
1. Cell next to Symbol in "Wash Sale?" column set to "Yes"
2. The Loss from the previous sale of the stock in Column X to be populated as a positive number in Column D of the current stock purchase.
3. Current Symbol highlights (I should be able to figure this out with Conditional Formatting)
4. The price / share in Column K will update based on the current purchase price plus number of shares purchased divided by the carried over loss in Column D
I am attaching an extract of my current spreadsheet. You will see two stocks (UPC & MBRX) for which I am trying to accomplish these goals. I've also added "Notes" to the cells where I'm trying to populate the data.
There are two other sets of symbols in the attached spreadsheet that shouldn't be affected by this formula (RAIL & WIMI).
RAIL was sold for a profit the first time so no loss to carry over
WIMI was split when trying to purchase 100 shares and neither entry has a SOLD date.
I thought using the COUNTIFS function would work but I'm stumbling with the criteria of <30 Days from the date in the "A" column.
If someone can help me out with this, or let me know what functions I need to use, it would be greatly appreciated.
Bookmarks