Note that there are some explanatory texts on larger screens.

plurals
  1. POBlackberry changePassword not working on openfire
    primarykey
    data
    text
    <p>I am using below code to change password of login user on openfire but this returns nullpointer exception.</p> <p>I have taken the reference from the below link:</p> <p><a href="http://xmpp.org/extensions/xep-0077.html#usecases-changepw" rel="nofollow">http://xmpp.org/extensions/xep-0077.html#usecases-changepw</a></p> <pre><code> if(use_ssl){ final SecureConnection sc = (SecureConnection) Connector.open("ssl://" + this.server + ":" + this.port+this.connectionMask, Connector.READ_WRITE); is = sc.openInputStream(); os = sc.openOutputStream(); this.reader = new XmlReader(is); this.writer = new XmlWriter(os); try{ String stream="&lt;stream:stream to='204.93.197.136' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' version='1.0'&gt;"; os.write(stream.getBytes()); os.flush(); do { reader.next(); } while ((reader.getType() != XmlReader.END_TAG) || (!reader.getName().equals("stream:features"))); for (Enumeration enu = listeners.elements(); enu.hasMoreElements();) { XmppListener xl = (XmppListener) enu.nextElement(); } String sendRequest="&lt;iq type='set' to='204.93.197.136' id='change1'&gt;&lt;query xmlns='jabber:iq:register'&gt;&lt;username&gt;"+Jxa.loginUserName+"&lt;/username&gt;&lt;password&gt;"+newPassword+"&lt;/password&gt;&lt;/query&gt;&lt;/iq&gt;"; os.write(sendRequest.getBytes()); os.flush(); int count=0; do { reader.next(); if(reader.getName().equals("error")){ count++; } } while ((reader.getType() != XmlReader.END_TAG) || (!reader.getName().equals("iq"))); for (Enumeration enu = listeners.elements(); enu.hasMoreElements();) { XmppListener xl = (XmppListener) enu.nextElement(); } }catch (Exception e) { System.out.println(e); UiApplication.getUiApplication().invokeLater(new Runnable(){ public void run(){ Dialog.alert("Record Not Updated"); } }); } } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload