Thanks for your answer, I was looking at the wrong documentation. Did fix everything but an error in connection.login() line. It says: "The type javax.security.sasl.SaslException cannot be resolved. It is indirectly referenced from required .class files". Im stuck at this point. |Any idea?
try{
ConnectionConfiguration config = new ConnectionConfiguration("10.0.0.4",5222);
XMPPConnection connection = new XMPPTCPConnection(config);
connection.connect(); // This line has an error.
connection.login("test","test");
}
catch (SmackException e) {
e.printStackTrace();
}
catch (java.io.IOException e)
{
e.printStackTrace();
}
catch (XMPPException e) {
e.printStackTrace();
}