On Mon, Jul 30, 2012 at 4:43 AM, MMM <[email protected]> wrote: > If I call bindService() method, its giving me error as bindService() > method is not defined. >
It is defined, but in the Context class. If you don't understand why you can't arbitrarily call a method defined in another class from another unrelated class, you need to spend some more time learning Java. > So, my question is that, do I need any class which is extended from a > component like Activity/Service to bind my service or can I bind the > service directly from simple Java class? > You either extend Activity, Service or another Context-derived class yourself or you pass an instance of a Context to this simple Java class. ------------------------------------------------------------------------------------------------- TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

