dasdsdsaadsdsadasdasadas
New Member
- Joined
- Jan 16, 2014
- Messages
- 2
I want to do this with only formula, not any scripts.
I want to be able to Remove everything BEFORE the LAST occurrence of the a period (and keep the cell blank if there isn't a period present).
Ex: This table shows what I need it to do.My current formula handles rows 2-4. However, I need help with row 5.
<tbody>
</tbody>The formula below works great at removing everything after last occurrence of the period. However, it returns the cell value if a period isn't present in column A (as shown below).
=TRIM(LEFT(RIGHT(SUBSTITUTE(A2,".",REPT(" ",LEN(A2))),LEN(A2)),LEN(A2)))
Ex:
<tbody>
</tbody>
I want to be able to Remove everything BEFORE the LAST occurrence of the a period (and keep the cell blank if there isn't a period present).
Ex: This table shows what I need it to do.My current formula handles rows 2-4. However, I need help with row 5.
A | B | Note | |
2 | helloworld.pdf | removed everything before last period | |
3 | hi.hop.doc | doc | notice this has two periods. it needs to remove everything BEFORE the last period |
4 | happytimes\document.txt | txt | removed everything before last period |
5 | document1 | Since a period is not present. I need it to be blank. |
<tbody>
</tbody>
=TRIM(LEFT(RIGHT(SUBSTITUTE(A2,".",REPT(" ",LEN(A2))),LEN(A2)),LEN(A2)))
Ex:
5 | document1 | document1 | Since a period is not present. I need it to be blank. The formula is currently returning the value in column A when a period isn't present. |
<tbody>
</tbody>
Last edited: