Looking for a way for a service to prevent a windows box from sleeping.

Is the SetThreadExecutionState api call the only way via .NET (C# or F#)?