I'm not 100% sure but it seems like overkill to create a new thread just to monitor a variable. Under what conditions can that variable change and why does it need to be monitored constantly ? If it's part of INI settings u can keep it on the free store. A user will typically not interact directly with an INI file and any changes directly made should be loaded only when the program is restarted...
Actually i am developing a service and a gui in c# the service and gui will interact through INI,there is an option in GUI to give time restart service at a particular time.
Now in my service i have to continuously check the time written in INI with current system time and restart the service if time matches
it may be the case that GUI might not be running or the end user have shut down the GUI after doing all the setting.
Are you saying that the user will sometimes modify the INI without the gui ?
The gui is the user's communication with the service. When the gui is off the service should have all of those settings updated for itself and not ever check that one of those settings changed until the gui is back online (and more specifically, like kbw said, it is not until the gui detects a change in the settings from the user should it notify the service).