관리 메뉴

드럼치는 프로그래머

[안드로이드] 외부Activity ,Service 호출 본문

★─Programing/☆─Android

[안드로이드] 외부Activity ,Service 호출

드럼치는한동이 2013. 5. 20. 14:04
Intent intent = new Intent(Intent.ACTION_MAIN);
intent.setComponent(new ComponentName("패키지명", "클래스"));

startService(intent);

//또는

startService(Activity);


일단 갤러리에서 사진 선택하기

Intent intent = new Intent();
intent.setAction(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
startActivityForResult(intent, 1);

[출처] http://blog.naver.com/PostView.nhn?blogId=p14406&logNo=120175548285

Comments