0

Use a updating variable from an activity to another activity

I have two activity in Android studio.in activity 1 I gave a int activity from db and in activity 2 I use from int variable.when user click on next button in activity 1 go to next record.but in activity 2 int variable is not apdate to next record.how to gave a int variable from activity 1 that use to activity 2 that be updated.sorry for my bad English language.

25th Dec 2017, 2:27 PM
Ali_vbpro
Ali_vbpro - avatar
2 ответов
0
you can out extra data in your intends with .putExtra(data) in your now started activity you can get the data from the intend
25th Dec 2017, 3:16 PM
Jeremy
Jeremy - avatar
0
my problem is that activity 2 that I want use var in it is dbhelper and havent oncreate method
26th Dec 2017, 6:52 AM
Ali_vbpro
Ali_vbpro - avatar