반응형
Notice
Recent Posts
Recent Comments
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
Archives
Today
Total
관리 메뉴

Do Something IT

[안드로이드] java.lang.reflect.InvocationTargetException 이 발생한 경우 본문

Android/Error

[안드로이드] java.lang.reflect.InvocationTargetException 이 발생한 경우

아낙시만더 2011. 6. 13. 14:22
반응형
출처 : http://northface.tistory.com/1 

java.lang.reflect.InvocationTargetException

Normally "java.lang.reflect.InvocationTargetException" occurs when java compiler finds 
2 different classes with same name in 2 different packages. 
when u r importing both classes at a time and when you r trying to create object of that class 
it throws "java.lang.reflect.InvocationTargetException" exception .

The solution is that when you are creating the object of the class use package name 
also along with class name so that compiler knows what class it has to use.

- answer by google -

해석을 하면 InvocationTargetException이 발생한 이유가 
자바 컴파일러가 2개의 서로 다른 패키지 안의 같은 클래스를 찾은 경우 에러가 발생한다고 되어 있다.
해결 방법은 객체를 생성할 때 패키지명을 써서 경로를 표시해서 컴파일러가 알 수 있게 하라고 되어있다.
 
반응형
Comments