OnClick change tablerow background color
问题 So I'm trying to find an easy way to get the background color or a table row to change when its clicked on. I've been trying to find a way to call what the background color is and check it but I haven't found a way to call the color. Here is what I have right now. RowName = (TableRow) findViewById(R.id.RowName); RowName.setBackgroundColor(Color.TRANSPARENT); RowName.setOnClickListener(new View.OnClickListener() { public void onClick(View v) { if (RowName.equals(Color.TRANSPARENT)) RowName