If Snake.java is not part of your project, obviously you can't reference Snake.class.
However you can use the fully qualified java name of the class (e.g "com.blah.myproject.Snake" as a string) with Intent.setClassName(). http://code.google.com/android/reference/android/content/Intent.html#setClassName(java.lang.String, java.lang.String) R/ On Fri, Nov 28, 2008 at 8:41 PM, souvik <[EMAIL PROTECTED]> wrote: > > Thanks for the response!!! > > However, the problem is, both r different project.....(two complete > different application) > > My code:::::::::::::::::::::::: > > account.java > ================================================== > MyAccount.setOnClickListener(new View.OnClickListener() { > public void onClick(View view) { > startActivity(new Intent(account.this, Snake.class)); > }}); > ================================================== > where "account" is my project class. and "Snake" is the other project > class (android snake application) which m trying to launch on click. > > Getting one error msg: "Snake can not resolve this type " ,create > snake class. > > What could be the problem! > > -souvik > > > > On Nov 28, 10:53 pm, Mark Murphy <[EMAIL PROTECTED]> wrote: >> souvik wrote: >> > Now if i want to launch android calculator when i click that >> > button, what i have to do? >> >> 1. Find an Intent that will open that application -- you might try >> browsing through the roster at: >> >> http://www.openintents.org/en/applications >> >> 2. Call startActivity() on that Intent >> >> -- >> Mark Murphy (a Commons Guy)http://commonsware.com >> >> Android Training on the Ranch! -- Mar 16-20, >> 2009http://www.bignerdranch.com/schedule.shtml > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

