So I'm trying to use an autoCompleteTextView in my project and my problem is that the autoCompleteTextView is not in the main.axml, but in the pager_item.axml so when I use
ArrayAdapter autoCompleteAdapter = new ArrayAdapter(this, Android.Resource.Layout.SimpleDropDownItem1Line, autoCompleteOptions);
the build is succesful, but the progrem crash at the start saying Object reference not set to an instance of an object.
when the SetContentView is set to pager_item.axml it works fine, but i dont want to set the content view, because i still need the main.axml.
so my question is what sould i use instead of this when my autoCompleteTextView is not on the active layout.