Android Viewpager Display specific fragment -


i know if possible display specific fragment in view pager. have @ moment gridview , onclick sends id via intent viewpager. view pager has 6 items. how go displaying third fragment? (with id of 2).

use viewpager setcurrentitem method. want param smoothscroll false, seems it's been @ position:

viewpager.setcurrentitem(2, false); 

Comments

Popular posts from this blog

android - Inheriting from Theme.AppCompat* -

broadcastreceiver - android BOOT_COMPLETED not received if not activity intent-filter -

basic authentication with http post params android -