Delphi – How do I check if Variant is TDATETIME?

I have an object, it has a value, but the value can be an integer, string, boolean or TDateTime. So, it is a Variant.

I use VarType() to check its type, but since VarType() does not have’varDate’ or’varDateTime’, I use’varDouble’ because as far as I know, TDateTime is a double.

But it will fail. I also can’t use it to check if Variant is TDateTime. Is there a way, or should I make some kind of variable to determine the type of the value and use it to check it?

Your assumption is incorrect; there is actually a varDate.

p>

I have an object, it has a value, but the value can be an integer, string, boolean or TDateTime. So, it is a Variant.

I use VarType () to check its type, but since VarType() does not have’varDate’ or’varDateTime’, I use’varDouble’ because as far as I know, TDateTime is a double.

But this will Failed. I also can’t use to check if Variant is TDateTime. Is there a way, or should I make some kind of variable to determine the type of the value and use it to check it?

Your assumption is incorrect; there is actually a varDate.

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 3136 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.