Reputation: 21
Let's say the user enters 1.234.567,89
or 1,234,567.89
or 1 234 567,89
in any excel cell one by one and in all the above cases the user should get 1234567,89
in the output cell.
Upvotes: 0
Views: 182
Reputation: 1
=ARRAYFORMULA(IF(LEN(A1:A),
IFERROR(REGEXREPLACE(A1:A, "\s|\.", ),
REGEXREPLACE(""&A1:A, "\s|\.", ",")), ))
Upvotes: 0
Reputation: 75860
Excel
Try TEXT()
with a custom format:
=TEXT(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(A1,",",""),".","")," ",""),"[>=100]#\,#0;#")
Google Spreadsheets
Try using REGEXREPLACE()
:
=TEXT(REGEXREPLACE(TEXT(A1,"@"),"[ ,.]",""),"[>=100]#\,#0;#")
Upvotes: 2