I want to new activity when i click an image.
I already write activity android:name=.openPdf in manifestfile.
but it shows me an error:-
"android.content.ActivityNotFoundException: Unable to find explicit activity class {Parsing.this/openPdf.class}; have you declared this activity in your AndroidManifest.xml?
"
Code ::
iv1.setOnClickListener(new View.OnClickListener()
{
public void onClick(View v)
{
// Toast.makeText(getApplicationContext(), "hello",Toast.LENGTH_SHORT).show();
Intent pdf=new Intent(Parsing.this,openPdf.class);
startActivity(pdf);
}
});
Please make sure like your activity which you are launching is in the same package, then and then you can write like
android:name=.openPdfelse need to use the full class name with package.