Java tutorial
//package com.java2s; import android.content.Context; import android.content.Intent; import android.net.Uri; public class Main { public static void dialog(Context context, String inputStr) { Intent phoneIntent = new Intent("android.intent.action.CALL", Uri.parse("tel:" + inputStr)); context.startActivity(phoneIntent); } }