How to convert two dates to millis by using clock component?

I Have two dates
EX: 01/01/20 and 10/01/20
and i want compare these dates with
=>
=<
but getting error

Show what you did and what you are trying to achieve.

i tried this
777777

That’s not correct. The date converted to a string is not a date anymore. It’s just a string for displaying it in a familiar way for our understanding.
When comparing dates, compare them in instants or in milliseconds. Do not format them.

2 Likes

And please don’t duplicate topics.

ltalo can you some example plzz

Here is your solution. Convert the dates to Instants (make instant block) then compare.

2 Likes

I don’t know if the instants by themselves can be compared without converting them to milliseconds, haven’t tried it yet, so try that if you want.

2 Likes

Thank you @Italo for Example

it works

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.