最近,我從GitHub下載了一個(gè)代碼,并將其與我的android studio同步。在這樣做的過程中,我遇到了很多錯(cuò)誤和問題,并以某種方式解決了大多數(shù)問題。但是,我現(xiàn)在遇到的最后一個(gè)問題是我的android studio無法找到類“ FloatingActionButton”,如您在此屏幕截圖中所見要注意的是,早期的許多其他類,包括“ AppCompatActivity”都無法解析。更改依賴項(xiàng)以解決以下問題dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'com.android.support:appcompat-v7:27.1.1' implementation 'com.android.support.constraint:constraint-layout:1.1.2' testImplementation 'junit:junit:4.12' androidTestImplementation 'com.android.support.test:runner:1.0.2' androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'}但是,即使在更改了依賴關(guān)系之后,仍然干凈地構(gòu)建項(xiàng)目,執(zhí)行“ Invalidate Caches / Restart ...”,“ FloatingActionButton”的問題仍然存在。誰能幫我解決這個(gè)問題嗎?
無法解析符號(hào)“ FloatingActionButton”
繁華開滿天機(jī)
2021-04-09 14:11:31