2015-06-07 192 views
0

在引用類CardView方法setCardBackgroundColor被定義,但Eclipse沒有看到它。我如何獲得這種方法是可見的?缺少方法setCardBackgroundColor

Missing method setCardBackgroundColor

+0

您使用哪種版本的CardView? – Blackbelt

+0

@Blackbelt,如何知道CardView的版本?我使用支持庫版本22.2。 –

+1

我正在使用'compile'c​​om.android.support:cardview-v7:21.0。+''並且我擁有它 – Blackbelt

回答

1

導入正確版本的CardView。 如果無法確定正確的版本,請更新sdk,然後通過導航到sdk \ extras \ android \ support \ v7來導入CardView。