Activity를 이동할 때, Intent에 putExtra로 조건을 식별(1번 탭이면 intenger로 1을..2번 탭이면 integer 2를...) 적용하여 다음 Activity에서 조건에 맞게 수행하면 되지 않을까요? if 1번버튼 클릭 Intent i = new Intent(activity2.this, activity2.class); i.putExtra("message", 1); startActivityForResult(i,0); if 2번버튼 클릭 위와 동일하나 i.putExtra("message", 2); 로 메시지를 날려주고 그 다음 Activity에서 Intent intent = getIntent(); int message = List.getList(intent.getIntExtra("message",0)); 형식으로 받고 if message==1 에 맞는 1번탭 디스플레이, 2에 맞는 수행으로 진행하면 2번탭 디스플레이 이런 식으로 하면 되지 않을까요?
2010.04.07 21:04:24
yally
답변 감사 드려요..
한번 시도 해봐야겠네요..
2010.04.07 21:15:12
noeek
아 GetList부분은 제가 하고 있던 부분 긁어 넣었더니 잘못 들어갔네요...지운다는게 그만..^^; 수고하세요!
Intent에 putExtra로 조건을 식별(1번 탭이면 intenger로 1을..2번 탭이면 integer 2를...)
적용하여
다음 Activity에서 조건에 맞게 수행하면 되지 않을까요?
if 1번버튼 클릭
Intent i = new Intent(activity2.this, activity2.class);
i.putExtra("message", 1);
startActivityForResult(i,0);
if 2번버튼 클릭
위와 동일하나
i.putExtra("message", 2);
로 메시지를 날려주고 그 다음 Activity에서
Intent intent = getIntent();
int message = List.getList(intent.getIntExtra("message",0));
형식으로 받고
if message==1 에 맞는 1번탭 디스플레이, 2에 맞는 수행으로 진행하면 2번탭 디스플레이
이런 식으로 하면 되지 않을까요?