Android Studio Can't resolve fragmentActivity and ViewPager imports

后端 未结 5 1686
野性不改
野性不改 2021-01-13 10:11

I follow the tutorial of developing swipe-able tabs. When I import:

import android.support.v4.app.FragmentActivity;
import android.support.v4.view.ViewPager;         


        
5条回答
  •  我在风中等你
    2021-01-13 10:32

    I have solved it. I installed everything but I did not import the external library into my library. It was not installed automatically during creation of the new project. So I just opened the project structure and imported the dependencies -> add support-v4 library.

    Btw, thanks you guys for helping me a lot and posting the suggestion to me.

提交回复
热议问题