Answer the question
In order to leave comments, you need to log in
Excel: Convert dimensions from mm to cm if some values are string?
There is a file with several thousand lines.
The columns indicate the dimensions in millimeters. It can be either a number or a string. Example:
Length, mm
1310
560
870/930
The numbers are clear, we divide by 10 and that's it. But what about values like "870/930" ?
Answer the question
In order to leave comments, you need to log in
for LibreOffice Calc:
=IF(ISNUMBER(A1),A1/10,CONCAT(TEXT(LEFT(A1,FIND("/",A1,1)-1)/10,"0"),"/",TEXT(RIGHT(A1,LEN(A1)-FIND("/",A1,1))/10,"0")))
=ЕСЛИ(ЕЧИСЛО(A1);A1/10;СЦЕПИТЬ(ТЕКСТ(ЛЕВСИМВ(A1;ПОИСК("/";A1;1)-1)/10;"0");"/";ТЕКСТ(ПРАВСИМВ(A1;ДЛСТР(A1)-ПОИСК("/";A1;1))/10;"0")))
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question