I know how to compare two string is same or not.this is coding for compare two strings TextView t,t1;
String s,s1; s=t.getText().toString(); s1=t1.setText().
If you want to check if the two images are absolutely equal then get the bytes from both, and compare two arrays with element-by-element check.