How to transport information between Activities

Asked

Viewed 56 times

3

I am a beginner in Android and I have the following problem. I have a screen (Activity) where is informed the condition of payment and the type of payment.

inserir a descrição da imagem aqui

Clicking on the payment condition field opens another screen with a list of payment terms

inserir a descrição da imagem aqui

When I click on an item in the list I select an item from that list back to the previous screen where it loads the values of the selected item as can be seen in the first image. But when I click on the payment type field performs the same process opens a new screen with the list of payment types and when clicking on an item in the list goes back to the previous screen with the payment type information. Only when returning to the screen loads the payment type information, but clears the information previously loaded from the payment method.

  • How should I treat so that the previously filled information is not lost?
  • Please make a Copy of these images, leave only the relevant part.

  • Place the code you are using to return to the previous screen and to pass this data between the screens.

  • Gives a read on maintaining screen states. https://developer.android.com/training/basics/activity-lifecycle/recreating.html?hl=pt-br

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.