अंतर्निहित गतिविधि कॉल
लक्ष्य फ़िल्टर आप अपनी गतिविधि तो अन्य एप्लिकेशन एक कार्रवाई के माध्यम से अपनी गतिविधि कॉल कर सकते हैं के लिए कार्रवाई बनाने के साथ:
<activity android:name=".BrowserActivitiy" android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="http"/>
</intent-filter>
</activity>
।
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.example.com"));
startActivity(intent);
स्पष्ट गतिविधि कॉल
आप एक फोन है कि वास्तव में इंगित करता है बनाने के जो गतिविधि वर्ग का उपयोग करें:
Intent intent = new Intent(this, ActivityABC.class);
startActivity(intent);
Here's an additional reference
स्रोत
2012-12-11 04:26:17