Convert Time string to Datetime format

Hi all, currently I am importing data from a Jason string output. In the data, there is a datetime string which looks like this: “Fri Dec 03 06:22:00 UTC 2021”. I am struggling to convert it to the date time format as “dd MMM yyyy HH:mm:ss”. I have tried parse but Uipath gave me error: “string is not regconized as a valid date time”. After the conversion, I need to compare it to the datetime I have in another format with the required format so converting it to string or date time is okay for me as long as it is in the same format “dd MMM yyyy HH:mm:ss”. Appreciate all suggestions. Thank you.

Welcome to the forum



Welcome to forums

Check below for your reference


Thank you. It worked :smiley. My incorrect code was using DDD instead of ddd.