angular.js - android.view.InflateException?
世界只因有你
世界只因有你 2017-05-15 17:00:36
0
1
774

android.view.InflateException: Binary XML file line #8: Error inflating class android.webkit.WebView?

  1. layout:

android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" android:padding="3dip">      

- Acivity
package com.example.fiz.myapphome;

import android.graphics.Color;
import android.os.Bundle;
import android.support.v4.view.ViewPager;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.webkit.WebView;

import com.example.fiz.myapplication.R;

/**

  • Created by Fiz on 16/4/13.

  • 显示文章详情页面
    */

public class ArticleInfoActivity extends AppCompatActivity {

private WebView webView_home_artilce_info; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.home_article_info);

// Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar_home_article_info);
// toolbar.setTitle("文章详细内容");
// toolbar.setSubtitle("文章详细内容 ");
// toolbar.setBackgroundColor(Color.parseColor("#303F9F"));
// toolbar.setNavigationIcon(R.drawable.ic_left);
//// webView_home_artilce_info = (WebView) findViewById(R.id.webView_home_article_info);
// init();
// toolbar.setNavigationOnClickListener(new View.OnClickListener() {
// @Override
// public void onClick(View v) {
// ArticleInfoActivity.this.finish();
// }
// });

webView_home_artilce_info = (WebView) findViewById(R.id.webview); webView_home_artilce_info.loadUrl(""); }

}

世界只因有你
世界只因有你

Antworte allen (1)
巴扎黑

最后找到解决办法了就是简单的Clean project一下再重新编译就好了

    Neueste Downloads
    Mehr>
    Web-Effekte
    Quellcode der Website
    Website-Materialien
    Frontend-Vorlage
    Über uns Haftungsausschluss Sitemap
    Chinesische PHP-Website:Online-PHP-Schulung für das Gemeinwohl,Helfen Sie PHP-Lernenden, sich schnell weiterzuentwickeln!