Sharing data between views
| Mon, 2005-05-16 14:05 | |
|
Hi,
In my app I'd like to switch from the main view to the Media Gallery view, then select an image and switch back to the main view with the selected image. How can I make Media Gallery return the location of the file I selected, or more generaly, how can I share data between the differents views of an application? |
|






Forum posts: 122
I do this by keeping data with the appUi and paasing the appUi instance to all views.
Regards,
kurtrips
Forum posts: 12
So can we make appUi and an external view exchange messages?, or that the external view return a message when leaving?
Forum posts: 2
When changing view to a remote application ActivateViewL(...), you can only pass information to that application. However there is not way to receive any "response" from that application. The only way would be if that application would change the view back to your application with that data.
However if you want to write to separate applications for yourself and pass information between them you can always exchange data by creating files in a common directory. This could also be the way you can use the camera application on the phone, by monitoring the directory where the application saves the images and thus see when it creates a new file.
Hope this is somewhat useful.