I am trying to execute swipe command from my Apk using
process = Runtime.getRuntime().exec(\"adb shell input swipe 250 300 -800 300\");
You need to put INJECT_EVENTS permission in your manifest:
uses-permission android:name="android.permission.INJECT_EVENTS"