1 button.setOnClickListener(v -> {
2 Intent intent = new Intent(v.getContext(), SecondActivity.class);
3 v.getContext().startActivity(intent);
4 });
5
6//how to start activity in adapter android
1override fun onClick(v: View?) {
2 val intent = Intent(v.context, TimerActivity::class.java)
3
4 v.context.startActivity(intent)
5}