At startup store the API-url in the Registry.
In normal mode, store in key HKCU\Software\SABnzbd\api (value "url").
In Service mode, store in key HKLM\SYSTEM\CurrentControlSet\Services\SABnzbd\api (value "url").
When the program stops, the key is removed.
When SABnzbd is started with an NZB file as parameter, it will use the registry entry to get the API-url.
First the HKCU key is tried, if that does not exist, the HKLM key is used instead.
The registry entry can also be used by third-party utilities.
Fixed a bug where "net stop sabnzbd" would not notify SABHelper.