简体   繁体   English

ActivityNotFoundException:未找到处理 Intent { act= dat="url" 的活动

[英]ActivityNotFoundException: No Activity found to handle Intent { act= dat="url"

I received a log during debugging我在调试期间收到了一条日志
He appeared on some mobile phones, and I don't know how to make it reappear他出现在一些手机上,我不知道如何让它重新出现
The following is the error log and source code oh,This link points to an advertisement以下是错误日志和源码哦,这个链接指向一个广告
But I didn't open the ad但是我没有打开广告
I suspect it's advertising on the web我怀疑它在 web 上做广告
and act is null!并且 act 为空! I don't understand我不明白

android.content.ActivityNotFoundException: No Activity found to handle Intent { act= dat=https://mob66.bbzwonline.com/... }
    at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:2066)
    at android.app.Instrumentation.execStartActivity(Instrumentation.java:1720)
    at android.app.Activity.startActivityForResult(Activity.java:5258)
    at androidx.fragment.app.FragmentActivity.startActivityForResult(FragmentActivity.java:676)
    at android.app.Activity.startActivityForResult(Activity.java:5216)
    at androidx.fragment.app.FragmentActivity.startActivityForResult(FragmentActivity.java:663)
    at android.app.Activity.startActivity(Activity.java:5587)
    at android.app.Activity.startActivity(Activity.java:5555)
    at com.ruifenglb.www.ad.AdWebView$1.shouldOverrideUrlLoading(AdWebView.java:55)
    at android.webkit.WebViewClient.shouldOverrideUrlLoading(WebViewClient.java:83)
    at org.chromium.android_webview.AwContentsClientBridge.shouldOverrideUrlLoading(chromium-TrichromeWebViewGoogle.apk-stable-410410183:16)
    at android.os.MessageQueue.nativePollOnce(Native Method)
    at android.os.MessageQueue.next(MessageQueue.java:336)
    at android.os.Looper.loop(Looper.java:181)
    at android.app.ActivityThread.main(ActivityThread.java:7562)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)

code代码

@SuppressLint("SetJavaScriptEnabled")
    private void initSetting() {
        addJavascriptInterface(new AdJavascriptInterface(), "AdJavascriptInterface");
        setWebViewClient(new WebViewClient() {
            @Override
            public void onPageFinished(WebView webView, String s) {
                webView.loadUrl("javascript:(" + jsimg + ")()");
                EventBus.getDefault().postSticky(new CloseSplashEvent());
            }

            @Override
            public boolean shouldOverrideUrlLoading(WebView view, String url) {
                Uri uri = Uri.parse(url);
                Intent intent = new Intent(Intent.ACTION_VIEW, uri);
                getContext().startActivity(intent);
                return true;
            }

        });

        WebSettings webSettings = getSettings();
        webSettings.setJavaScriptEnabled(true);
        webSettings.setUseWideViewPort(true);
        webSettings.setLoadWithOverviewMode(true);
        webSettings.setLoadsImagesAutomatically(true);
    }

Check if device has any app that can handle url检查设备是否有任何可以处理 url 的应用程序

Kotlin Kotlin

if (resolveActivity(packageManager) != null) {
        Uri uri = Uri.parse(url);
        Intent intent = new Intent(Intent.ACTION_VIEW, uri);
        getContext().startActivity(intent);
        return true;
    }

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 android.content.ActivityNotFoundException:没有找到处理意图的活动{act=android.intent.action.VIEW dat=PendingIntent{} - android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=PendingIntent{ } android.content.ActivityNotFoundException:未找到任何处理Intent的活动{act = android.intent.action.GET_CONTENT - android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.GET_CONTENT android.content.ActivityNotFoundException: 没有找到处理意图的活动 { act=activity2.application1 (有额外的) } - android.content.ActivityNotFoundException: No Activity found to handle Intent { act=activity2.application1 (has extras) } android.content.ActivityNotFoundException:未找到任何处理Intent的活动{act = login_filter(有其他功能)} - android.content.ActivityNotFoundException: No Activity found to handle Intent { act=login_filter (has extras) } ActivityNotFoundException:没有找到处理 Intent {(有额外功能)} 的活动 - ActivityNotFoundException: No Activity found to handle Intent { (has extras) } 找不到用于处理Intent {的活动“ act = android.intent.action.CALL dat =电话号码:1}? - No Activity found to handle Intent{ act=android.intent.action.CALL dat=Phone number:1 }? Android错误:“ android.content.ActivityNotFoundException:未找到用于处理Intent的活动” - Android error : “android.content.ActivityNotFoundException: No Activity found to handle Intent” android.content.ActivityNotFoundException:未找到用于处理Intent的活动 - android.content.ActivityNotFoundException: No Activity found to handle Intent 致命异常:android.content.ActivityNotFoundException:未找到处理 Intent 的活动 - Fatal Exception: android.content.ActivityNotFoundException: No Activity found to handle Intent 找不到用于处理意图的活动{act = android.intent.action.View} - No activity found to handle intent { act=android.intent.action.View }
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM