How to login in android app using Gmail Crdentials. Can anyone provide me link of tutorial which describe whole integration process. Can anybody share any example code for gmail Integration to login in android App.
Asked
Active
Viewed 1,256 times
2 Answers
0
You simply need to add this code to your loginActivity:
List<String> googleAccounts = new ArrayList<String>();
Account[] accounts = AccountManager.get(this).getAccounts();
for (Account account : accounts) {
if (account.type.equals("com.google")) {
googleAccounts.add(account.name);
}
}
Credits to original answer by Ozone
-
Hi Nezam, I have a doubt. if suppose i created fresh gmail login. i did not create google plus. is it possible to get only gmail gmail email and his profile info while gmail oauth integration in my android application. – harikrishnan Oct 13 '14 at 11:53