In my main activity if I apply this code I got error gridviewadapter() cannot be applied,
it is problem in context this.
GridViewAdapter adapter = new GridViewAdapter(this, R.layout.grid_item_layout, result);
if I apply it like this :
public MainActivity (Context context) {
mContext = context;
}
GridViewAdapter adapter = new GridViewAdapter(mContext, R.layout.grid_item_layout, result);
I got this error in logcat
java.lang.InstantiationException: can't instantiate class com.justedhak.www.i.MainActivity; no empty constructor
I am trying to pass asynctask arraylist value to mainactivity .. how to fix that ?