Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need the Date
Message
From
14/03/2017 08:35:08
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
01649027
Message ID:
01649030
Views:
86
This message has been marked as a message which has helped to the initial question of the thread.
Likes (1)
>I have a new product that is licensed by the year - anyone know the best way to grab the current Date out in web land somewhere (instead of just checking the local computers clock)? Code sample would also be appreciated. I am using VFP 9 SP2.
>
>Thanks in advance....

A very very simple way of doing this, without too much of a fuss, is to check on a highly available web site (W3, Google, ...) and read its date.
LOCAL HttpCall AS MSXML2.ServerXMLHTTP60

m.HttpCall = CREATEOBJECT("MSXML2.ServerXMLHTTP.6.0")
m.HttpCall.Open("Get", "https://www.w3.org")
m.HttpCall.Send()
? m.HttpCall.Getresponseheader("Date")
----------------------------------
António Tavares Lopes
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform