E
Eric S.
Hi,
I have a sheet that contains long ranges of serialnumbers. In some cases,
the serial number is formatted incorrectly and then contains a period "."
The period can be found in any position in the cell, but typically appears
as the first or the last character.
I am looking for a macro to remove the period from the cell. I have found a
helpful formula on this forum but I cannot / don't know how to include that
into a macro.
The formula is
=IF(LEFT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",IF(RIGHT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",MID(B2,2,LEN(B2)-2),MID(B2,2,LEN(B2)-1)),IF(RIGHT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",LEFT(B2,LEN(B2)-1),B2))
thanks
I have a sheet that contains long ranges of serialnumbers. In some cases,
the serial number is formatted incorrectly and then contains a period "."
The period can be found in any position in the cell, but typically appears
as the first or the last character.
I am looking for a macro to remove the period from the cell. I have found a
helpful formula on this forum but I cannot / don't know how to include that
into a macro.
The formula is
=IF(LEFT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",IF(RIGHT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",MID(B2,2,LEN(B2)-2),MID(B2,2,LEN(B2)-1)),IF(RIGHT(CONCATENATE(LEFT(B2),RIGHT(B2)))=".",LEFT(B2,LEN(B2)-1),B2))
thanks