I am new to android and working on conference manager application .I do not know how to access the dial paid after the call is started in android can someone help me in this case or provide some sample codes for my references.Thank you.This is my call() the first number should be a conference number so i used action call and the second number is a conference pin ,every step will have delay in time
private void call(int profileid) {
ProfileDo profile = adapter.getProfile(profileid);
int stepCount = 0;
long previsouStepDelay=0;
for (StepDO step : profile.getSteps()) {
String url = "tel:" + step.getValue();
stepCount++;
if (stepCount == 1) {
Intent callIntent = null;
callIntent = new Intent(Intent.ACTION_CALL, Uri.parse(url));
startActivity(callIntent);
} else {
try {
Thread.sleep(previsouStepDelay*1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
Intent callIntent = null;
callIntent = new Intent(Intent.ACTION_DIAL, Uri.parse(url));
//callIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(callIntent);
}
previsouStepDelay = step.getDelay();
}
}
Can anyone tell me what mistake i did and how can i improvise this?