ActivityNotFoundException?

后端 未结 10 772
滥情空心
滥情空心 2020-12-01 14:25

I am getting an ActivityNotFoundException in the following code:

Main.java

Intent intent = new Intent();
     intent.setAction(\"com.tes         


        
10条回答
  •  生来不讨喜
    2020-12-01 15:09

    Be sure to declare your activity in the manifest.xml within the aplication:

    
        
    
    

    To start the new Activity:

    Intent intent = new Intent(main.this, YourNewActivity.class);
    startActivity(intent);
    

    Where main stands for the current activity,

提交回复
热议问题