Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to properly autoshutdown an app
Message
De
31/12/2013 04:12:10
 
 
À
30/12/2013 16:29:38
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01591090
Message ID:
01591141
Vues:
77
>>>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.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform