我知道他們改變了資源類中的常量如何存儲在ADT 14中,但是我怎樣才能獲得xml項的id
,因爲r.id.item
現在給出錯誤?xml id在冰淇淋三明治
例如這給了我一個錯誤
mPager = (ViewPager)findViewById(R.id.pager);
這是我的XML
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<android.support.v4.view.ViewPager
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/pager"/>
</LinearLayout>
這是在庫中?他們只是在圖書館項目中更改,編輯:什麼錯誤? – dten
它不是一個logcat錯誤,我不能編譯。錯誤說'ID無法解析或不是字段'我試圖測試片段尋呼機支持示例http://developer.android.com/resources/samples/Support4Demos/src/com/example/android/supportv4/app /FragmentPagerSupport.html – tyczj