본문 바로가기

Accessing Android Resources By Name at Runtime For example: I have a file bug.png in the "/res/drawable/ ", so i get its ResourceID with the following code: int resID = getResources( ) .getIdentifier ( "org.anddev.android.testproject:drawable/bug" , null , null ) ; // or int resID = getResources( ) .getIdentifier ( "bug" , "drawable" , "org.anddev.android.testproject" ) ; 더보기
앤드로이드 어플리케이션 설치 및 환경 설정 #2 - install the Android App. & set the configuration #2 2. Android App. public deploy 하기 Android App.를 개발하여 에뮬레이터에서도 돌려보고 자신의 디바이스에서도 돌려봤다면 이제 더 넓은 세계로 나가보자~~^^ 다른 사용자에게 apk. 형태로 배포하기 위한 방법(Android Market 포함)을 알아보겠다. 이번에 예제로 사용될 어플리케이션은 Lotto Generato(2008년 10월경에 Notepad 어플리케이션을 참고하여 제작) 이다. 배포하기 위한 어플리케이션이므로 배포이후에 업그레이드/유지를 위한 버젼관리는 필수이다. AndroidManifest.xml 파일에 아래의 정보가 필수적으로 필요하다. -AndroidManifest.xml 파일 Android Market에 배포하기 위해선 빨간 글씨로 된 4개의 태그가 정의.. 더보기
앤드로이드 어플리케이션 설치 및 환경 설정 #1 - install the Android App. & set the configuration #1 1. Android Eclipse Plugin을 이용한 G1 디바이스에 배포 (Self Deploy) 역시 데모 어플리케이션은 Hello Android가 제격이다. Android USB Driver가 정상적으로 설치되었다면, cmd 창에서 adb devices를 입력하면 아래와 같은 결과를 볼수있다. 정상적으로 연결되었다면 list of devices에 식별자를 볼 수 있다. 이제 이클립스를 실행 시키고 Hello Android 프로젝트를 실행시키면 애뮬레이터에 올라가는게 아니라 실제 G1 디바이스에 올라가게 된다. HelloAndroid Project Run Console Window 위의 그림과 같이 Hello Android app.가 인스톨 되면 G1 디바이스를 보면 애뮬레이터로만 보던 어플리케이션.. 더보기