as you can see in the next screenshot of my program, the screen includes several frames, and each frame has two types of images and a textual representation. I want another action to start when the user clicks on the frame (either imageView or textView).
In the code, I wrote:
final FrameLayout frame01 = (FrameLayout) findViewById(R.id.frame01);
but when I add the following code, the program will work!
frame01.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Toast.makeText(Main.this, "Frame01 Selected", Toast.LENGTH_SHORT).show();
}
});
what should I do? Thanks

Hesam source
share