How to change coma to colon

Hi,

I would like to change in my string coma to colon, eg. 10,50 to 10:50.
How could I do this?

Hi @Krzysztof,

output=input.Replace(",",":")
replace.xaml (4.8 KB)

Regards,
Omkar P

1 Like

Hi,

I have another problem:
11,50 as count I have to assign to time 11:30 (hours, as string of course). Do you have any idea how to do?

you want change format time?

No, I need string to type into on HR software. Im my data table I have 11,50 but correct format in software is 11:30.

take one assign activity you know datatable that row or column do something like below

newvariable=dt.row(1).replace(",":")

typeint activity pass this newvariable

Yes, but hot to change 11,50 to 11:30?

you want to change 11,50 to 11:(here you want 30 static value)?
you want to change 11,50 to 11(: here you want colon format)30?

Generally I would like convert string 11,50 to string 11:30.

Pls try this
output=input.Replace(",",":").Replace(“50”,“30”)

1 Like

Great!

There is another problem. If I have 50,50, I will get 30:30 against 50:30. It means that 50 to 30 should change only after colon (not before). Do you have any solution? Maybe split 50,50 to two columns, change text in second column (after coma - from 50 to 30), and finally agregate it?

I solved the problem.

1 Like

Great :clap: :clap:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.