Rocky Goyal
Rocky Goyal

Reputation: 21

How to convert dots to commas decimal notations using excel formula

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

Answers (2)

player0
player0

Reputation: 1

=ARRAYFORMULA(IF(LEN(A1:A), 
 IFERROR(REGEXREPLACE(A1:A, "\s|\.", ), 
 REGEXREPLACE(""&A1:A, "\s|\.", ",")), ))

0

Upvotes: 0

JvdV
JvdV

Reputation: 75860

Excel

Try TEXT() with a custom format:

=TEXT(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(A1,",",""),".","")," ",""),"[>=100]#\,#0;#")

enter image description here

Google Spreadsheets

Try using REGEXREPLACE():

=TEXT(REGEXREPLACE(TEXT(A1,"@"),"[ ,.]",""),"[>=100]#\,#0;#")

enter image description here

Upvotes: 2

Related Questions