को हल नहीं कर सकता है मेरे पास मेरे लेआउट में ImageView
है, नीचे कोड देखें। जब मैं अपने लॉन्चर आइकन होने के लिए src
विशेषता निर्धारित करने में कोशिश कर रहा हूँ, मैं निम्नलिखित त्रुटि मिलती है:प्रतीक @ drawable/ic_launcher
Cannot resolve symbol '@drawable/ic_launcher'
ic_launcer.png मेरी ड्रॉएबल फ़ोल्डर में जोड़ा जाता है, छवि नीचे देखें। मैं अपने ImageView
में अपनी छवि का संदर्भ क्यों नहीं दे सकता?
परियोजना संरचना:
Layout.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_weight="1"
android:orientation="horizontal"
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:src="@drawable/ic_launcher"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<LinearLayout
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
'ड्रायबल' और 'मिपमैप' फ़ोल्डरों के बीच अंतर को समझाने के लिए धन्यवाद। – Marcus