DateTime Format1

can anyone plz solve this error? which is i don’t understand.

Hi @Yogita_Gaikwad1 ,
What is input and expect result?


This is my excel & i want to take StartDate & StartTime from excel

Hi @Yogita_Gaikwad1

Do you want to take only time in Start Time or whole thing in the Start Time Column?

I tried both vaule but not work & i want only take time in start time

Okay @Nguyen_Van_Luong1

In that case for giving time you have to provide the below expression in Start time field.

DateTime.ParseExact(CurrentRow(6).toString, "MM/dd/yyyy HH:mm:ss", System.Globalization.CultureInfo.InvariantCulture).toString("HH:mm:ss")

Hope it helps!!

Then it better to change the format the cells in the excel. To change the format of StartTime Column values use the Fomat cells activity first.

When open the set format, change the Data Type to Time and Time format give the format like HH:mm:ss like below.

Note - You have to use the Format cells activity inside the Use excel file activity.

Hope you understand!!


this is right ?


then in start time what shoud i give
can u do in my workflow?

Hi @Yogita_Gaikwad1

**Note**:dateTimeValue and convertedDate are of datetime datatype variables.

Assign dateTimeValue= DateTime.ParseExact(CurrentRow(6).ToString, "dd/MM/yyyy HH:mm:ss", System.Globalization.CultureInfo.InvariantCulture)
Assign convertedDate=DateTime.ParseExact(CurrentRow(5).ToString, "MM/dd/yyyy", System.Globalization.CultureInfo.InvariantCulture)

Hope it helps!!

can u plz send workflow of the screenshot?

I already attached the scrnshot

I am not able to see screenshot clearly

New (9.8 KB)

can u do in my workflow?