Click here to Skip to main content
16,016,317 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I use date time field and get from sql server for comparsion.
if end user or hackers tampered date time in sql machine
how to get internet date time in vb.net application
so that we can compare internet time and pc time.

i am new to vb.net
could you kindly help me in this situtation?
Posted

1 solution

There's no such thing as "internet time". You can get the current time from a SNTP server. There's a CodeProject article that provides a SNTP client class:

SNTP Client in C#[^]

Once you retrieve the time from the desired SNTP server, you can compare that datetime to the datetime retrieved from your SQL server box.

 
Share this answer
 
v2
Comments
thatraja 28-Dec-10 11:41am    
good answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900