LoginSignup
0

More than 5 years have passed since last update.

<Android>「android.view.InflateException」に関して

Posted at

今回の出来事

開発中にエミュレータ起動をしていたのだが、デバッグ作業しようとしたら、起動時に端末落ちが発生した。

エラー内容を確認したところ、

android.view.InflateException: Binary XML file line #17: Error inflating class ImageButton

が出ていた。初歩的なミスなのかもしれないと原因を探ってみた。

原因

今回、Imagebuttonを実装していたのだが、srcとして格納していたImageの格納先フォルダを間違えていたようだった。

※元々の格納先 : 「drawable-v24」  ⇒ 正しい格納先 :「drawable

実行端末がAPI19だったので、起ったエラーであり、API24以下の環境下だったら、問題なかったらしい・・・

まだまだ慣れてないな・・・

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0