Help me??? How to implement searcview in recyclerview with native ads showing

41 views
Skip to first unread message

Yudi Zulkarnain

unread,
Sep 3, 2019, 2:18:09 AM9/3/19
to Google Mobile Ads SDK Developers
I get error

java.lang.NullPointerException: Attempt to invoke virtual method 'android.widget.Filter com.yudizulkarnain.mobilbanking.item.adapter.NativeAdsAdapter.getFilter()' on a null object reference
        at com.yudizulkarnain.mobilbanking.ItemFragment$10.onQueryTextChange(ItemFragment.java:594)

UnifiedNativeAdViewHolder.java
User.java
NativeAdsAdapter.java
ItemFragment.java

Mobile Ads SDK Forum Advisor Prod

unread,
Sep 3, 2019, 5:13:37 AM9/3/19
to dzulka...@gmail.com, google-adm...@googlegroups.com
Hi Yudi,

Thank you for reaching out to us.

With regard to your concern, you may use our Banner RecyclerView Example as a base reference in showing ads. However, the example I've provided is implementing a banner ad instead of native ad. With this, you just have to configure the load ad request with a Native ad format. You may check this Native ads implementation document for your reference.

Regards,
Teejay Pimentel
Mobile Ads SDK Team

ref:_00D1U1174p._5001UHFSQL:ref

Yudi Zulkarnain

unread,
Sep 4, 2019, 1:54:43 AM9/4/19
to Mobile Ads SDK Forum Advisor Prod, google-adm...@googlegroups.com
Thank you for your response. 
Reply all
Reply to author
Forward
0 new messages