[jdev] Unable to delete the user
Juan Antonio Gómez Moriano
moriano.jabber at gmail.com
Sat Mar 4 14:30:04 CST 2006
El jue, 02-03-2006 a las 08:53 -0800, chen yee tan escribió:
> I am using smack 2.1.0 Client API to connect to jabber.org (ejabberd).
Me too! please note that jivesoftware has a whole forum for that
> Below is the function to delete the user:
Here is how i do it
roster.removeEntry("somebody at someserver.net");
Where roster is a "Roster" object...
> public void deleteUser()
> XMPPConnection.DEBUG_ENABLED = true;
> XMPPConnection l_xmmpConnection = null;
> PrintLog("Delete user.");
> l_xmmpConnection = new XMPPConnection("noneworkstation", 5222);
> l_xmmpConnection.addPacketListener(this, new
> l_xmmpConnection.login("tancy", "tancy");
> AccountManager l_accountManager =
> PrintLog("User is deleted.");
> catch (Exception ex)
> PrintLog("Exception in deleteUser: " + ex.toString());
> After I ran, I got:
> E:\Jabber\API\Smack 2.1.0\code>java
> -classpath ../smack.jar;../smackx.jar;./ Test
> [01:23:39 AM] Delete user.
> [01:23:53 AM] Exception in deleteUser: No response from server.:
> I tried to run above function several times. Sometimes with above
> exception, the
> user is deleted.
> How come ? Is it a bug in ejabberd or I did wrong in the code ?
> Your help is really appreciated.
> Thanks !
> Yahoo! Mail
> Bring photos to life! New PhotoMail makes sharing a breeze.
More information about the JDev