On Thu, Jan 10, 2013 at 3:15 PM, Monty Jain <montyj...@gmail.com> wrote: > is it possible to call startactivityforresult from a non-activity class to > get the results.
No, sorry. > I have a class Class NonActivity(it doesn't derive from Activity as its not > a UI). This class will have bunch of functions(steps basically) to run. One > of the step requires to show UI(Activity) and then get the result(user enter > something). Then been able to use that data in next following steps. > > how can this be achieved without deriving from activity class as I don't > have UI component Collect the data before the first step, from your activity. > Basically reason for using Non-Activity class is that I want to encapsulate > the whole process into a class(API) then anyone who wants to use this class > can call its API. IMHO, such a library absolutely, positively should NOT be starting an activity. The developer using the library needs to have control over that behavior. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Aqui estão alguns sites onde você pode perguntar ou responder dúvidas sobre desenvolvimento de aplicações para Android: http://www.andglobe.com -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en