Hi,
I’m using this code in assign:
I get an error:
Can anyone please advise?
Thank you
thanks @Shiva_Nikhil ,
Now I don’t get an error,but the first date I get is 2019…there are more recent dates…
Please advise
can you try this
(From r In dt.AsEnumerable
Order By datetime.ParseExact(r("ColumnName").ToString.Trim,{"MM/dd/yyyy hh:mm:ss","MM/dd/yyyy HH:mm:ss","dd/MM/yyyy"},system.Globalization.CultureInfo.InvariantCulture).Date
Descending
Select r).CopyToDataTable
Hello!
Can you try this? please.
dt.AsEnumerable.OrderByDescending(Function(r) DateTime.ParseExact(r(“ColumnName”).ToString().Trim,
{“MM/dd/yyyy hh:mm:ss”, “MM/dd/yyyy HH:mm:ss”, “dd/MM/yyyy”},
CultureInfo.InvariantCulture).Date).CopyToDataTable
Thanks Mariemily Silva for your help
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.