stuck CSEntry app with intent
Posted: February 24th, 2024, 11:38 am
When dynamically passing keys via an intent from an Android app to CSEntry in Android, I encounter an issue when attempting to open the CSEntry app repeatedly for different cases. After each attempt, without accepting the case (uncompleted data entry. user just close app by using android keys), I receive an 'Application Startup Error' stating that CSEntry could not open the 'name' of the app (.pen).
This code is working if I softly handle only one case,but I have to call pff with different keys repeatedly, for each cases.and user may escape without completing case.
I utilize the following code to open the app by passing 'var1' (for demonstration purposes):
String var1 = etext.getText().toString();
Intent intent = new Intent();
intent.setComponent(new ComponentName("gov.census.cspro.csentry", "gov.census.cspro.csentry.ui.EntryActivity"));
intent.putExtra("PffFilename", "test.pff");
intent.putExtra("OperatorID", "John Doe");
intent.putExtra("StartMode", "add");
intent.putExtra("variable", var1);
startActivity(intent);
Upon experimenting, I observed that when I attempt to run the app within CSEntry itself (by that time), I encounter a message stating 'CSEntry is already running another application. You can only run one application at a time.' It appears as though the app is hidden in the background.
to resolve I need to reinstall app. I use onStop() with stop(1) hoping to terminate app but no luck. any suggestion pls
This code is working if I softly handle only one case,but I have to call pff with different keys repeatedly, for each cases.and user may escape without completing case.
I utilize the following code to open the app by passing 'var1' (for demonstration purposes):
String var1 = etext.getText().toString();
Intent intent = new Intent();
intent.setComponent(new ComponentName("gov.census.cspro.csentry", "gov.census.cspro.csentry.ui.EntryActivity"));
intent.putExtra("PffFilename", "test.pff");
intent.putExtra("OperatorID", "John Doe");
intent.putExtra("StartMode", "add");
intent.putExtra("variable", var1);
startActivity(intent);
Upon experimenting, I observed that when I attempt to run the app within CSEntry itself (by that time), I encounter a message stating 'CSEntry is already running another application. You can only run one application at a time.' It appears as though the app is hidden in the background.
to resolve I need to reinstall app. I use onStop() with stop(1) hoping to terminate app but no luck. any suggestion pls