How to remove the "/" from the date

Cordial greeting community

How to remove the “/” from the date when it arrives 02/12/2019 and leave it as 02122019

2 Likes

Hi
if the input is
strinput = “02/12/2019”
then use a assign activity like this
stroutput = strinput.Replace(“/”,“”)

Cheers @Sebasthian_Arias

1 Like

If it’s a solution but print the date like this: 20191202 but I need to print it 02122019
If you know how I can order it, I thank you.

Note: Could you help me with the issue of deleting duplicates I thank you

1 Like

@Sebasthian_Arias,

Try like the following DateTime conversion method.

Convert.ToDateTime("02/12/2019").ToString("ddMMyyyy")
1 Like

Yah sure
the expression be like this
Datetime.ParseExact(str_input.Replace(“/”,“”).tostring,“ddMMyyyy”,System.Globalization.CultureInfo.InvariantCulture).ToString(“yyyyMMdd”)

this will type as yyyyMMdd as we have mentionted the ToString(“yyyyMMdd”)
if we want we can change the format out there in the ToString method

Cheers @Sebasthian_Arias

1 Like

It also works I thank you very much @ Palaniyappan

1 Like

Cheers @Sebasthian_Arias

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