If a DSN is System wide, we need to write to the HKEY_LOCAL_MACHINE part of the registry not HKEY_CURRENT_USER which it's currently doing.
-- v5: odbccp32: SQLWritePrivateProfileStringW simplify creating registry keys. odbccp32: SQLWritePrivateProfileStringW check for existing DSN first. odbccp32: SQLGetPrivateProfileString use ConfigMode to determine key retrieval.