c# - Windows Service wait until computer is ready -
i have windows service fails when restart computer , not know where. (i surround on try catch block , never hit catch block!)
anyways think time problem. if make process wait 15 seconds works fine. service connects web service on local network. correct approach of initializing service. computers faster others 1 computer might need 5 second delay , others may require 25 seconds delay. appropiate way of solving problem?
what doing right on while loop try connect local web service hosted on local network. if not able connect try again on next 30 seconds. logging data file , reason service keeps running , throws no exceptions.every 30 seconds should see new line saying "attempting connect" on log dont line! no exceptions! if go see service on task manager, windows 7 says service running. how should solve problem?
it sounds service dependent on service on system started yet. windows has built in support allowing specify other services service depends on. suggest maybe setting service dependent on "workstation" service.
Comments
Post a Comment