6 Years
Discussion Span
Last Post by adnysam

use select getdate() on SQL and executescalar to get the value.
Assign the value to a var and use it in statusstrip or wherever.
I'm not sure what you are doing with the timer control though.

PS: Why does it has to be the SQL date/time and not the system running the code? Reading it from SQL will be way slower than locally. If you are planning on using the timer to refresh it - by reading it again - then it's gonna be way slow.


If I use select getdate() with timer, appear an error.

I want to place this software on 4-5 pcs with one server and want that statusstrip shows only Server Pcs date & time instead of local datetime. that the reasonwhile I use this.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.