To start an activity, you need a Context.

You can get it by calling view.getContext() - which will actually be a reference to the activity (if the view is inside one).

-- Kostya

19.01.2011 9:56, vivin joy пишет:
       i have two Activities. one is the MainActivity and other an
activity where a user could type anything. i have a class called
commentclass which extends View class. the main.xml layout uses this
class. this main.xml is displayed using the mainActivity . the
commentclass has a ontouch event. in that event, when a particular
region is touched, i need to start the second activity. how do i do
that?? pls help me with this. i googled a lot , but i was not able to
find the correct answer.

thanks



--
Kostya Vasilyev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com

--
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

Reply via email to