Not able to load .vcf contacts from MS Outlook

Hello,

i just tried to deal with some vcard files, which i saved from my MS Outlook contacts.

Everytime when the program tries to load a vcard, an exception “header doesn’t correspond to vCard format” is thrown.

I am using aspose python library

Code :

def run():
dataDir = “Data/”
#ExStart: LoadingContactFromVCF
VCardContact.load(dataDir + “Contact.vcf”)

    apiContact = MapiContact.from_vcard(dataDir + "Contact.vcf")
    #ExEnd: LoadingContactFromVCF

Thanks,
Tejas

@TejasA

Could you please ZIP and attach your .vcf file here for testing? We will investigate the issue and provide you more information on it.

Contact.zip (631 Bytes)

Attched zip file which contains sample .vcf file.

@TejasA

We have tested the scenario using the latest version of Aspose.Email for Java 22.1 and have not found the shared issue. So, please use Aspose.Email for Java 22.1.

@tahir.manzoor

I want to use python library is Aspose.Email version 22.1 available for python ?

@TejasA

Please download the latest version of Aspose.Email for Python via .NET from here:

@tahir.manzoor Seeing same issue with latest 20.8 version also

Code :

    from aspose.email import MailMessage
    from aspose.email.mime import HeaderCollection
    import aspose.email.mapi.msg as msg
    from aspose.email.mapi import MapiMessage, MapiContact
    from aspose.email.personalinfo.vcard import VCardContact

    def run():

    	#dataDir = "Data/"
    	#ExStart: LoadingContactFromVCardWithSpecifiedEncoding
    	contactReadFromFile = MapiContact.from_vcard("Sample 2-1644507767.vcf", "UTF-8")
    	#ExEnd: LoadingContactFromVCardWithSpecifiedEncoding
    	
    if __name__ == '__main__':
        run()

@TejasA

We have logged this problem in our issue tracking system as EMAILNET-40577. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

@TejasA

We suggest you please use the latest version of Aspose.Email for Python via .NET 22.3.1 to avoid the shared issue.