Hello everybody. I'm new here and this is my very first post.
My Excel experience is limited but nevertheless created over time several sheets with success. However, now I'm stuck at this.
'Stock Options'!D3 contains .AAPL220729P140
What I need is this: Find the position of the first P from the right, but give out number of characters from the beginning (left) to that P. In this case the correct result would be 11. Not 4.
Those are stock option symbols. If there isn't a P in the stock symbol but only a P for Put my formula works. I'm using this formula:
=IFERROR(LOOKUP(2^15,SEARCH("P",'Stock Options'!D3,ROW(INDIRECT("1:"&LEN('Stock Options'!E3))))), "0")
I added IFERROR because if there is no P the result would be #n/a. But because I'm doing the same for the character C, I then need the function =MAX to determine the higher value. So I replaced #n/a with a 0.
The length of the symbols varies. Otherwise it would be easy when the P is always at the same position. But this is not the case. I hope this is possible without VBA because that would be a complete new world for me.
My Excel experience is limited but nevertheless created over time several sheets with success. However, now I'm stuck at this.
'Stock Options'!D3 contains .AAPL220729P140
What I need is this: Find the position of the first P from the right, but give out number of characters from the beginning (left) to that P. In this case the correct result would be 11. Not 4.
Those are stock option symbols. If there isn't a P in the stock symbol but only a P for Put my formula works. I'm using this formula:
=IFERROR(LOOKUP(2^15,SEARCH("P",'Stock Options'!D3,ROW(INDIRECT("1:"&LEN('Stock Options'!E3))))), "0")
I added IFERROR because if there is no P the result would be #n/a. But because I'm doing the same for the character C, I then need the function =MAX to determine the higher value. So I replaced #n/a with a 0.
The length of the symbols varies. Otherwise it would be easy when the P is always at the same position. But this is not the case. I hope this is possible without VBA because that would be a complete new world for me.