开发者

Making phone call in android

开发者 https://www.devze.com 2023-03-29 11:31 出处:网络
Can we make a phone call programmatically using android? That is, can we do what micr开发者_如何转开发ophone does exactly while making a call? (converting audio energy to electricenergy programmatical

Can we make a phone call programmatically using android? That is, can we do what micr开发者_如何转开发ophone does exactly while making a call? (converting audio energy to electric energy programmatically)


If you are looking for this,

Intent callIntent = new Intent(Intent.ACTION_CALL);
        callIntent.setData(Uri.parse("tel:" + 123456));
        startActivityForResult(callIntent, 1);

provide this permission in your manifest

<uses-permission android:name="android.permission.CALL_PHONE" />

This will help you to make a call from your app.


Intent callIntent = new Intent(Intent.ACTION_CALL);                
    callIntent.setData(Uri.parse("tel:01670100682"));
    startActivity(callIntent);
0

精彩评论

暂无评论...
验证码 换一张
取 消