- Knox SDK
This article guides you through the steps on how to clear the input history on your device's keyboard, including saved login information. Following these steps prepares the device for a new user without requiring a factory reset or work profile removal.
How do I clear the keyboard input history on my device using the Knox SDK?
In order to clear the keyboard history for a user, invoke the Knox SDK API ApplicationPolicy.wipeApplicationData(), with "com.sec.android.inputmethod" passed in the parameter. For example:
Although the default Samsung keyboard is passed into the API call, all keyboards' histories will be removed by this API since it removes both cache and stored application data.
To ensure the white bar is removed while still hiding the navigation buttons, invoke SystemManager.setStatusBarMode() instead. The following is an example of how to do this:
CustomDeviceManager cdm = CustomDeviceManager.getInstance(); SystemManager sm = cdm.getSystemManager(); sm.setStatusBarMode(CustomDeviceManager.HIDE);
The ApplicationPolicy.wipeApplicationData() method does not affect autofill settings configured through Settings > Language and input > Autofill service, or any other keyboard settings.
You can disable autofill on the Samsung browser by using the public boolean setAutoFillSetting (boolean enable) API with the "com.samsung.android.knox.permission.KNOX_BROWSER_SETTINGS" permission.
For sample MVNO configurations, see the Knox Developer documentation.