• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

App Inventor Android Accessibility service

dawit3036

Lurker
Hi There, am developing USSD Android App and i am using Accessibility service to get responses text from ussd code. But I cannot get a way to submit a number to the running ussd code for doing further steps ?

As you see on the screenshot, how to submit '1' and click 'Send' using Accessibility service or other else

3furu.jpg


Please help me any one who knows about this topic .... code to get the response text from the running ussd is below. And I am sorry for my stupid english !!


Java:
@Override
public void onAccessibilityEvent(AccessibilityEvent event)  {

   Log.d(TAG, "onAccessibilityEvent");
   String text = event.getText().toString();
   if (event.getClassName().equals("android.app.AlertDialog")) {
       performGlobalAction(GLOBAL_ACTION_BACK);
       Log.d(TAG, text);
       Intent intent = new Intent("com.times.ussd.action.REFRESH");
       intent.putExtra("message", text);
   }

}
 
Back
Top Bottom