Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/178.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android 我不知道';在安卓系统中无法获得拨号屏幕_Android - Fatal编程技术网

Android 我不知道';在安卓系统中无法获得拨号屏幕

Android 我不知道';在安卓系统中无法获得拨号屏幕,android,Android,试试这个 btnCall.setOnClickListener(new OnClickListener() { public void onClick(View v) { Intent intentCall=new Intent(); intentCall.setAction(android.content.Intent.ACTION_CALL);

试试这个

btnCall.setOnClickListener(new OnClickListener()
        {
            public void onClick(View v) 
            {
                Intent intentCall=new Intent();
                intentCall.setAction(android.content.Intent.ACTION_CALL);
                intentCall.setData(Uri.parse("Calling no.."+edtText.getText()));
                startActivity(intentCall);
            }
        });
授予应用程序调用AndroidManifest的权限

Intent callIntent = new Intent(Intent.ACTION_CALL);
callIntent.setData(Uri.parse("tel:"+edtText.getText().toString()));
startActivity(callIntent);

添加这个,edtText.getText().toString()
Intent callIntent = new Intent(Intent.ACTION_CALL);
callIntent.setData(Uri.parse("tel:"+edtText.getText().toString()));
startActivity(callIntent);
<uses-permission android:name="android.permission.CALL_PHONE" />