티스토리 뷰

profile_age.setText(profile.getAge());


getAge()가 int타입이고 profile_age가 텍스트뷰였는데 오류가 안나길래 그냥 실행했더니 앱이 죽음

로그캣봤더니 android.content.res.Resources$NotFoundException #0x2 이케 써있음


https://stackoverflow.com/questions/11189545/android-android-content-res-resourcesnotfoundexception-string-resource-id-0x


이거보고 

profile_age.setText(profile.getAge());를

profile_age.setText(Integer.toString(profile.getAge())); 로 바꿨더니 잘됨




댓글