第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機(jī)立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

我的 xml 代碼中有一個錯誤,導(dǎo)致所有應(yīng)用程序停止

我的 xml 代碼中有一個錯誤,導(dǎo)致所有應(yīng)用程序停止

慕尼黑5688855 2023-12-10 15:01:20
我有一個錯誤,這是我的代碼dependencies {    implementation fileTree(dir: 'libs', include: ['*.jar'])    implementation 'androidx.appcompat:appcompat:1.1.0'    implementation 'androidx.constraintlayout:constraintlayout:1.1.3'    testImplementation 'junit:junit:4.12'    androidTestImplementation 'androidx.test:runner:1.2.0'    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'    implementation 'androidx.cardview:cardview:1.0.0'對于 xml<android.support.v7.widget.CardView            android:id="@+id/card_view"            android:layout_width="match_parent"            android:layout_height="293dp"            app:cardBackgroundColor="@color/card"            app:cardCornerRadius="10dp"            app:cardElevation="5dp"            app:cardUseCompatPadding="true">            <TextView                android:id="@+id/textView4"                android:layout_width="432dp"                android:layout_height="510dp"                android:text="TextView" />            <WebView                android:id="@+id/webview"                android:layout_width="match_parent"                android:layout_height="match_parent"                tools:ignore="WebViewLayout" />        </android.support.v7.widget.CardView>使用這行代碼,應(yīng)用程序停止,我僅嘗試使用依賴項(xiàng)行,并且我沒有放置 XML 代碼行,僅使用依賴項(xiàng)實(shí)現(xiàn)cardview行和 hid 并沒有停止,但是當(dāng)我放置該代碼行時對于 XML 文件,應(yīng)用程序停止。
查看完整描述

1 回答

?
犯罪嫌疑人X

TA貢獻(xiàn)2080條經(jīng)驗(yàn) 獲得超4個贊

您的 gradle 文件中有以下androidx版本:CardView

implementation 'androidx.cardview:cardview:1.0.0'

CardView但是您在布局文件中使用舊版本:

<android.support.v7.widget.CardView ... />

您必須在兩者中使用相同的版本。因此,將布局文件中的標(biāo)簽替換為:

<androidx.cardview.widget.CardView ... />


查看完整回答
反對 回復(fù) 2023-12-10
  • 1 回答
  • 0 關(guān)注
  • 158 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號