I tried the ADB method. Does it require root?
Without root I got this message:
Exception occurred while executing 'put':
java.lang.SecurityException: Permission denial: writing to settings requires:android.permission.WRITE_SECURE_SETTINGS
at com.android.providers.settings.SettingsProvider.enforceWritePermission(Unknown Source:30)
at com.android.providers.settings.SettingsProvider.mutateSecureSetting(Unknown Source:8)
at com.android.providers.settings.SettingsProvider.insertSecureSetting(Unknown Source:12)
at com.android.providers.settings.SettingsProvider.call(Unknown Source:512)
at android.content.ContentProvider.call(Unknown Source:0)
at android.content.ContentProvider$Transport.call(Unknown Source:30)
at com.android.providers.settings.SettingsService$MyShellCommand.putForUser(Unknown Source:85)
at com.android.providers.settings.SettingsService$MyShellCommand.onCommand(Unknown Source:619)
at android.os.BasicShellCommandHandler.exec(Unknown Source:27)
at android.os.ShellCommand.exec(Unknown Source:4)
at com.android.providers.settings.SettingsService.onShellCommand(Unknown Source:15)
at android.os.Binder.shellCommand(Unknown Source:0)
at android.os.Binder.onTransact(Unknown Source:148)
at android.os.Binder.execTransactInternal(Unknown Source:103)
at android.os.Binder.execTransact(Unknown Source:16)