VCardRootPackageVCardPackage Property
Gets the VCard metadata package.

Namespace: GroupDocs.Metadata.Formats.BusinessCard
Assembly: GroupDocs.Metadata (in GroupDocs.Metadata.dll) Version: 21.4
Syntax
public VCardPackage VCardPackage { get; }

Property Value

Type: VCardPackage
The VCard metadata package.
Remarks
Examples
This code sample demonstrates how to extract vCard fields along with descriptive parameters.
C#
using (Metadata metadata = new Metadata(Constants.InputVcf))
{
    var root = metadata.GetRootPackage<VCardRootPackage>();

    foreach (var vCard in root.VCardPackage.Cards)
    {
        if (vCard.IdentificationRecordset.PhotoUriRecords != null)
        {
            // Iterate all photos represented by URIs
            foreach (var photoUriRecord in vCard.IdentificationRecordset.PhotoUriRecords)
            {
                // Print the property value
                Console.WriteLine(photoUriRecord.Value);

                // Print some additional parameters of the property
                Console.WriteLine(photoUriRecord.ContentType);
                Console.WriteLine(photoUriRecord.MediaTypeParameter);
                if (photoUriRecord.TypeParameters != null)
                {
                    foreach (string parameter in photoUriRecord.TypeParameters)
                    {
                        Console.WriteLine(parameter);
                    }
                }
                Console.WriteLine(photoUriRecord.PrefParameter);
            }
        }
    }
}
See Also