I have found the answer. We can implement such functions: 1) creating a new type of contacts (see the link at the end of the answer);
2) creating an Activity that will perform this action:
if (getIntent().getData() != null) { Cursor cursor = managedQuery(getIntent().getData(), null, null, null, null); if (cursor.moveToNext()) { String username = cursor.getString(cursor.getColumnIndex("DATA1")); TextView tv = (TextView) findViewById(R.id.profiletext); tv.setText("This is the profile for " + username); } } else {
3) adding a special intent to the Activity in our Manifest.xml:
<activity android:name=".ProfileActivity" android:label="Profile"> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="vnd.android.cursor.item/vnd.org.c99.SyncProviderDemo.profile" /> </intent-filter> </activity>
The answer (and the full tutorial) was found here .
Anton Derevyanko
source share