I see default 12/09/1899 in my date column.
Here are the expressions I used.
1)======threw the 1899 error
datetime.FromOADate(CDBL(in_qi_TransactionItem(“ActiveDate”).ToString)).ToString(“MM/dd/yyyy”)
======threw an error saying string was not recognized as a valid date Time
DateTime.ParseExact(in_qi_TransactionItem(“ActiveDate”).ToString, “MM/dd/yyyy”, CultureInfo.InvariantCulture).ToString(“MM/dd/yyyy”)
======
Can anyone alternative expression? Thanks!
DateTime.ParseExact(in_qi_TransactionItem(“ActiveDate”).ToString, “MM/dd/yyyy”, CultureInfo.InvariantCulture).ToString(“MM/dd/yyyy”)
I think can you try once “dd/MM/yyyy” in place of “MM/dd/yyyy”
Can you put LogMessage activity which has in_qi_TransactionItem("ActiveDate").ToString just before activity which occur the exception?
Then check the value in Output panel.
Thank you for sharing.
-21 means 12/9/1899 in Excel Serial value. So where did you get this -21 from?
Is there possibility to get it from wrong column etc?
@Yoichi
It’s coming from the correct column. And it is a formula column. the date values to be carried to the next template with the date format. Please let me know if you want me share the excel file with you. Thanks!
The file was already read using the classic read range. My Bot account does not have O365 license as a result of that I do not use Excel Process Scope. If possible, I want to resolve using the expressions. Please let me know if I misunderstood you. Thanks a lot!
Let me try to explain a little bit
Column E is populated when there is data in Column C. We then populate a template column (on another separate file) data from column E after making sure that the data in Column E is converted to MM/dd/yyyy format. Can you please look into the attached excel file.
Here is also the expression I was trying to use that is resulting in 1899 error