Board index » cppbuilder » TDateTime Comparison?

TDateTime Comparison?


2006-06-01 10:18:56 PM
cppbuilder28
Hi,
i have two TDateTime variables;
TDateTime one,two;
i wanna compare them, if they are equal, i wanna do something...
if(one = = two )
do something
But unfortunately even they are NOT equal it goes in to the if block and
does something. How can i fix it?
thanks
 
 

Re:TDateTime Comparison?

"Cenk" < XXXX@XXXXX.COM >wrote:
Quote
i have two TDateTime variables;

TDateTime one,two;

i wanna compare them, if they are equal, i wanna do something...

if(one = = two )
do something

But unfortunately even they are NOT equal it goes in to the if block and
does something. How can i fix it?
Remove the semi colon at the end of the if() statement.
Alan Bellingham
--
ACCU Conference: 11-14 April 2007 - Paramount Oxford Hotel
 

Re:TDateTime Comparison?

"Cenk" < XXXX@XXXXX.COM >wrote in message
Quote
unfortunately even they are NOT equal it goes in to the if
block and does something. How can i fix it?
Please show your actual code.
Gambit
 

{smallsort}

Re:TDateTime Comparison?

"Alan Bellingham" < XXXX@XXXXX.COM >wrote in message
Quote
>But unfortunately even they are NOT equal it goes in to the if block and
>does something. How can i fix it?

Remove the semi colon at the end of the if() statement.

LOL!
Been there, got the tattoo on the forehead...
- Roddy
 

Re:TDateTime Comparison?

"Roddy Pratt" <roddy at spam fritter dot com>wrote:
Quote
Been there, got the tattoo on the forehead...
Best I can suggest when someone asks for help, multiple times, and NEVER
INCLUDES copy/pasted source.
(And I can tell that source wasn't, because it would never compile.)
Alan Bellingham
--
Team Thai Kingdom
<url:www.borland.com/newsgroups/>Borland newsgroup descriptions
<url:www.borland.com/newsgroups/netiquette.html>netiquette
 

Re:TDateTime Comparison?

Alan Bellingham wrote:
Quote

Remove the semi colon at the end of the if() statement.
I hate it when that happens.
Chris W