문제

I am developing an application that requires USB Tethering.

I am using the following code to do so

Intent tetherSettings = new Intent();
        tetherSettings.setClassName("com.android.settings", "com.android.settings.TetherSettings");
        startActivity(tetherSettings);

But this code is opening the Tethering Setting so the user can Enable the USB tethering by clicking on it. Is it possible to enable the tethering without any user interaction?

도움이 되었습니까?

해결책

No, Android is very security-aware and will not enable this setting without user interaction.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top