Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to properly autoshutdown an app
Message
From
31/12/2013 04:12:10
 
 
To
30/12/2013 16:29:38
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01591090
Message ID:
01591141
Views:
79
>>>There is also an HOUR() function, and numeric hour never exceeds 23, so you could use IF HOUR( TIME( ) ) = 23 in place of your current construct.
>>
>>not really - that should give function argument... invalid. Hour(Datetime()) much better ;-)
>
>Good catch... the one time I post w/o testing :(

just be proud to know that your personal murphy field is working a-ok - and please tell me you don't pre-test all your OS install posts ;-)
best way from CPU/machine POV probably would be to compare seconds() to a precalculated property - but that piece of code just does not look perf dangerous, so the most readable code to the maintainer probably is the "right" code, and your approach is the one easier to grok - at least to my reading style.
Previous
Reply
Map
View

Click here to load this message in the networking platform