Extract data from object

Hey there,

I’ve just startet to learn UiPath. I set up my first process which is connected to a dialogflow chatbot.

I have an argument which receives a specific date from the chatbot. At the moment I just put the argument inside of a message box.


My question is: How can I extract only the date “2020-09-18T 17:00:00+02:00” and convert it into a string to write the date in e.g. a microsoft office word file?

Thanks for your help in advance.

Best regards

Hello @max.mlr
That expression looks like JSONString. You could deserialize that into JObject or Dictionary.

You can search “How to deserialize a string into” that’s main thing of programming :slight_smile:

If you can’t find exact answer I could help you later.

Cheers :slight_smile:

1 Like

Thanks for your help, @abdullahtayhan

I tried to do that with the “Deserialize JSON” activity, but when I set the argument as Input (Json String) it says it cannot convert from Object to String. The argument has to be of type object, otherwise it doesn’t catch the object sent from dialogflow.

I also thought about using an expression like “termin(“fields”)(“date_time”)(“stringValue”).toString” but it also doesn’t work.

I believe I am doing something wrong :worried:

I believe I found the solution:

When I use “.ToString” I can assign the value to a variable of type String and output it without any issues.

But how can I extract only the date?