在Qt中获取联系人列表,可以使用Qt的联系人模块(Qt Contacts)。以下是一个简单的示例代码:
#include <QContactManager>
#include <QContact>
#include <QContactDetail>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactDisplayLabel>
#include <QContactName>
#include <QContactGuid>
#include <QContactFavorite>
#include <QContactAvatar>
#include <QContactPresence>
#include <QContactSyncTarget>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
#include <QContactVersion>
#include <QContactSortOrder>
#include <QContactStatusFlags>
#include <QContactDetailFilter>
#include <QContactManagerEngine>
#include <QContactFetchHint>
#include <QContactId>
#include <QContactPhoneNumber>
#include <QContactEmailAddress>
#include <QContactAddress>
#include <QContactUrl>
#include <QContactNote>
#include <QContactRelationship>
#include <QContactOrganization>
#include <QContactAnniversary>
#include <QContactBirthday>
#include <QContactGender>
#include <QContactNickname>
#include <QContactRingtone>
#include <QContactGlobalPresence>
#include <QContactTimestamp>
领取专属 10元无门槛券
手把手带您无忧上云