Example usage for android.content Intent ACTION_CALL

List of usage examples for android.content Intent ACTION_CALL

Introduction

In this page you can find the example usage for android.content Intent ACTION_CALL.

Prototype

String ACTION_CALL

To view the source code for android.content Intent ACTION_CALL.

Click Source Link

Document

Activity Action: Perform a call to someone specified by the data.

Usage

From source file:Main.java

public static void makeACall(String phonenUmber, Context context) {
    Intent callIntent = new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phonenUmber));
    context.startActivity(callIntent);//from  ww  w  .  ja  va 2s.co  m
}

From source file:Main.java

public static void callPhone(Context context, String phoneNumber) {
    context.startActivity(new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phoneNumber)));
}

From source file:Main.java

public static void call(Activity activity, String mobile) {
    try {//from w  w  w . j a v a2 s .c om
        Intent callIntent = new Intent(Intent.ACTION_CALL);
        callIntent.setData(Uri.parse("tel:" + mobile));
        activity.startActivity(callIntent);
    } catch (Exception e) {
        e.printStackTrace();
    }
}

From source file:Main.java

public static void callNum(Context context, String number) {
    Intent intent = new Intent();
    intent.setAction(Intent.ACTION_CALL);
    intent.setData(Uri.parse("tel:" + number));
    context.startActivity(intent);/*  w w w.ja  va 2 s.c  o m*/
}

From source file:Main.java

public static void callPhone(Context context, String phoneNumber) {
    Intent intent = new Intent();
    intent.setAction(Intent.ACTION_CALL);
    intent.setData(Uri.parse("tel:" + phoneNumber));
    context.startActivity(intent);//from www.  ja v  a  2s.  c  om
}

From source file:Main.java

public static void sysCall(Context context, String callTo) {
    Intent intent = new Intent(Intent.ACTION_CALL);
    intent.setData(Uri.parse("tel:" + callTo));
    context.startActivity(intent);/*from w  ww.ja v a2s. c  o  m*/
}

From source file:Main.java

public static void callTel(Activity activity, String number) {
    Uri uri = Uri.parse("tel:" + number);
    Intent intent = new Intent(Intent.ACTION_CALL, uri);
    activity.startActivity(intent);/*from  w  ww  .  ja  v  a2  s  .  c  o  m*/
}

From source file:Main.java

public static void makeCall(Context context, String phoneNumber) {
    Intent intent = new Intent(Intent.ACTION_CALL, Uri.parse("tel://" + phoneNumber));
    context.startActivity(intent);//w  w w . j a  v a  2s  . co  m
}

From source file:Main.java

public static void callPhone(Context mContext, String phoneNumber) {
    Uri uri = Uri.parse("tel:" + phoneNumber);
    Intent call = new Intent(Intent.ACTION_CALL, uri);
    mContext.startActivity(call);/*from   ww w. j  ava2s  .c o  m*/
}

From source file:Main.java

public static void startActionCall(String phoneNumber, Context cxt) {
    Uri phoneNum = Uri.parse("tel:" + phoneNumber);
    cxt.startActivity(new Intent(Intent.ACTION_CALL, phoneNum));
}