HI! i'm experiencing an error when i try to log in facebook. until
yesterday it whorks , but today doesnt. what is wrong??
Login fb = FacebookConnect.getInstance();
fb.setClientId("nnnnnnnnnnnnnnnn");
fb.setRedirectURI("http://www.xxxxxxxxxxx.com.ar");
fb.setClientSecret("n1n1n1n1n1n1n1n1n1n1n1n1n1");
fb.setCallback(new LoginCallback() {
public void loginSuccessful() {
}
public void loginFailed(String errorMessage) {
}
});
if (Storage.getInstance().readObject("token") != null) {
String auxToken =
Storage.getInstance().readObject("token").toString();
FaceBookAccess.setToken(auxToken);
fb.setAccessToken(new AccessToken(auxToken, ""));
}
if (!fb.isUserLoggedIn()) {
fb.doLogin();
} else {
// get the token and now you can query the Facebook API
String token = fb.getAccessToken().getToken();
// ...
FaceBookAccess.setToken(token);
}
//-----
User me = null;
try {
me = FaceBookAccess.getInstance().getUser("me");
} catch (Exception exp) {
Dialog.show("Error", "An error occurred while logging in: ",
"OK", null);
}
if (statLogin.validarUsuario(null, null, null, me.getId()) == true)
{
statParams.setParam("LastLoginMethod", "facebook");
statLogin.loggeado();
} else {
try {
formRegistro.show();
} catch (Exception ex) {
}
}
//----
}
thanks
If you are experiencing an issue please mention the full platform your
issue applies to:
IDE: NetBeans/Eclipse/IDEA
Desktop OS
Simulator
Device
--
You received this message because you are subscribed to the Google Groups
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit
https://groups.google.com/d/msgid/codenameone-discussions/1f31821a-b293-4cbe-95c7-ee42612b0bd2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.