Arda Çebi Arda Çebi - 5 months ago 47
Java Question

Making components invisible with button

How can I make a component on my MainUI invisible by pressing a button? I want to dismiss a warning box on my MainActivity with a button that says "Close" or with a cross image.

Button crossButton = (Button) findViewById(
Button button1 = (Button) findViewById(
//and so on

crossButton.setOnClickListener(new View.OnClickListener(){
    public void onClick(View v){
        //and so on