So, it turns out that anything you put into your own ExternalSource
will never get parsed and therefore (theoretically) never show up.  Or
am I doing something wrong?  The code looks like it will parse only
the information in ContactsDataKind and not the EditField node from
the following:

<ContactsSource xmlns:android="http://schemas.android.com/apk/res/
android">
    <ContactsDataKind
        android:mimeType="com.example.mimetype"
        android:icon="@drawable/icon"
        android:summaryColumn="data2"
        android:detailColumn="data3">
        <EditField column="data1" title="@string/sample_string" />
    </ContactsDataKind>
</ContactsSource>

Essentially, I have adding an account and the sync adapter working.
But when I try to create a new contact through the contacts app, I can
never see any of the fields I added in the XML structure defined by
"<meta-data android:name="android.provider.CONTACTS_STRUCTURE"
android:resource="@xml/contacts" />".  Has anyone figured out an
answer to this problem yet?  I've seen a few posts, but nothing with a
solid answer.

On Jan 12, 4:45 am, Jens <[email protected]> wrote:
> You could check the Email app - its the current location of the
> Exchange ActiveSync SyncAdapter implementation.
>
> http://android.git.kernel.org/?p=platform/packages/apps/Email.git;a=s...
>
> Note that this adapter isn't the complete story as any contacts you
> create with your custom accounts will be next to useless without
> looking into the wonky ExternalSource.java integration required for
> custom adapters (unless your happy with contacts that only contains a
> name and photo).
>
> http://android.git.kernel.org/?p=platform/packages/apps/Contacts.git;...
>
> Sources.java contains the "super-special-let's-not-use-our-own-API:s-
> because-that's-hard-work-and-might-require-us-to-actually-document-
> anything-or-heaven-forbid-test-it" if-statement that determines the
> layout of your contacts in the Contacts app - and gives super-special
> treatment to accounts with the type "com.google" or
> "com.android.exchange".
>
> ExternalSource.java contains the sparse and incomplete API
> documentation that you're going to have to use.
>
> On 9 Jan, 22:16, joebowbeer <[email protected]> wrote:
>
> > On Dec 10 2009, 7:03 am, ydario <[email protected]> wrote:
>
> > > I tried addingcontactscode to this project
>
> > >http://code.google.com/p/androidaccounts/
>
> > The referenced project no longer exists. Are there any similar
> > projects to check out? If not, could someone who has a handle on this
> > start anewproject?

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