Issue
I'm looking to make an app that adds a bunch of words to the users dictionary.
I know I can use UserDictionary.Words.AddWords however it is not actually adding the words to the dictionary.
It looks like "WRITE_USER_DICTIONARY" permission was removed in M, is there a different way to add words to a users dictionary or is that completely gone now?
Solution
UserDictionary.Words can no longer be accessed from Marshmallow (API 23) onwards.
Reference : Android Issue Tracker - Issue 199199
The user dictionary is now accessible only by the current spellchecker and keyboard. It was heavily abused by apps to scoop user dictionary. Out of the ten top apps using it there wasn't a single legit one. My favorite was the one which used a bug in keyguard to unlock the device after [it] "scans" [your] fingerprint from the screen! This is intended behavior.
Answered By - vishnu narayanan
Answer Checked By - Willingham (JavaFixing Volunteer)