Smack vcard.getAvatar() returns null problem

Hi ,

I am new to smack.When i am trying to get avatar using Smack Vcard it is giving null avatart.I am using below code

VCard vcard = new VCard();

vcard.load(connection,"");// load someone’s VCard

byte[] avatarBytes = vcard.getAvatar();

At above vcard.getAvatar() returning null simply.I have seen in documentation we should do with jabbar.I did not get

Is there some more patches should add to Smack api or alone smack3.1.0 will work.Please give me reply if any one have idea.


Madhusudhan Dumpa

pls any body have an idea how get an avatar plz share with me


Madhusudhan D

If you are using the android version ‘asmack’, take a look at this post:

“vCard” in the “vcard-temp” namespace has to be associated with a vCard-parser."

ProviderManager.getInstance().addIQProvider(“vCard”, “vcard-temp”, new org.jivesoftware.smackx.provider.VCardProvider());