Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DATETIME() Coding in VFP5.0
Message
From
23/02/1997 13:14:29
 
 
To
23/02/1997 13:06:56
Linda Morgan
Garden City Community College
Garden City, Kansas, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00021683
Message ID:
00021686
Views:
35
> Can anyone tell me why the following code used to work (under VFP50) and > now, all of a sudden, gives me an error message "Operator/operandi > mismatch" ? The underlying field is formatted for datetime and I haven't > changed anything else (that I'm aware of) to cause this sudden refusal to > work syndrome! Century is set on. Thanks in advance. > > IF !EMPTY(THIS.Value) < DATETIME() > = MESSAGEBOX("You need to enter a VALID date or time",1,"ERROR MESSAGE") > RETURN .F. > ELSE > RETURN .T. > ENDIF I kinda wonder why did it work in the first place !EMPTY() will return a logical value which you compare with a Datetime value IF !EMPTY(this.value) and this.value .Signature { margin-top: 12px; color: #666666; } .Signature a { color: #666666; }
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform