# How to get the currently logged-in username and password in ODK Collect using Java?

**URL:** <https://forum.getodk.org/t/how-to-get-the-currently-logged-in-username-and-password-in-odk-collect-using-java/17191>\
**Category:** Development\
**Tags:** odk-collect\
**Created:** [January 14, 2019, 3:05am UTC](https://forum.getodk.org/t/how-to-get-the-currently-logged-in-username-and-password-in-odk-collect-using-java/17191 "2019-01-14T03:05:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Abel\_Melquiades\_Call](https://getodk.b-cdn.net/user_avatar/forum.getodk.org/abel_melquiades_call/32/1727_2.png) [@Abel\_Melquiades\_Call](https://forum.getodk.org/u/Abel_Melquiades_Call)\
**Post date:** [January 14, 2019, 3:05am UTC](https://forum.getodk.org/t/how-to-get-the-currently-logged-in-username-and-password-in-odk-collect-using-java/17191/1 "2019-01-14T03:05:08Z")

</div>

I'm trying to figure out how ODK Collect works by scanning through the source code. I'm just new to Android Development and I couldn't wrap around how Preferences work.

Anybody here knows how to get the currently logged-in `username` and `password` in ODK Collect using Java?
