 <p>It looks like you want to create an intent and then start an activity with it. You can use the context from "collection" which you are already accessing. Here's some code which should get you going again:</p> <pre><code>public void onClick(View v) { Context context = collection.getContext(); Intent intent = new Intent(context, DashboardActivity.class); context.startActivity(intent); } </code></pre> <p>Note that you'll probably have to make collection become final.</p>