Date formating using UIpath from Excel

Hello! I have in Excel column date formating “dd.mm.yyyy”, but I need output on UiPath “mm.dd.yyyy”. How to do that? At the moment I am using TypeInto activity for browser automation with inputText: releaseDate.Replace(“.”,“”)

releaseDate is String variable

I would love to connect with you through teamviewer since I am new to UiPath :slight_smile:

Hi @Chris_Balance

Try this

releaseDate=DateTime.ParseExact("18.03.2023","dd.MM.yyyy",System.Globalization.CultureInfo.InvariantCulture).ToString("MM.dd.yyyy")

image

Hope this helps

image
I pasted this in type Into activity, but error shows up. Probably don’t know how to use your script then :smiley: sorry

Hi @Chris_Balance
Try this

DateTime.ParseExact(releaseDate,"dd.MM.yyyy",System.Globalization.CultureInfo.InvariantCulture).ToString("MM.dd.yyyy")
2 Likes

Worked! Thank you :slight_smile:

1 Like

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