I have a server running that notifies the user with a statusbar notification that opens my main activity, how can I pass data to my activity trough that intent?
相关问题
- How can I create this custom Bottom Navigation on
- Bottom Navigation View gets Shrink Down
- How to make that the snackbar action button be sho
- Listening to outgoing sms not working android
- How to create Circular view on android wear?
MainActivity
SecondActivity
Use
Intent.putExtra(..)
:This method is overloaded and takes various types as second argument: int, byte, String, various arrays..
To get the data out use appropriate getXYZExtra(). For String this is: