Android application - android

Whenever i login to application i need to enter the password.But next time when i enter the password it shows me complete password over the soft keyboard of android.I need to clear this
data from android memory.

If you don't want the password hint to be shown try adding the following to your EditText attributes
android:inputType="textFilter|textMultiLine|textNoSuggestions"

Related

Sendkeys() not release the Element in Android App using Appium

WebElementUserAccount=driver.findElement(By.xpath("//android.widget.EditText[#content-desc='User account']"));
UserAccount.click();
UserAccount.sendKeys("Test");
When I use this code it is not releasing the User account element it sends the text successfully but not came out of it
In the second element, I have to send the password but it will not come out from the first Element
When I use
WebElement UserName= driver.findElement(By.xpath("//android.widget.EditText[#content-desc='User account']"));
WebElement Password= driver.findElement(By.xpath("//android.widget.EditText[#content-desc='Password']"));
UserName.sendKeys("UserName");
The Android keybord open before sending the text and it starts writing in the second element
Use driver.hideKeyboard(); after entering text in your first element. Your keyboard might be hiding next element.
Whenever you do automation its better to turn off the text suggestion(predictive text) in the mobile keyboard.
Check whether the keyboard is displayed . If displayed use the following code:
driver.hideKeyboard();

Registered user check for lowercase or uppercase

I want to know how to check the existing users for either upper or lowercase when a new user is signing up. At present for example the followig two users can be registered
tom and Tom, both of these are considered as two separate users, so if this happens I want to sound off to the user that the username already exists. Where in code exactly can I do this?
You can create a textwatcher for the edittext where user enters loginname and when focus changes from the edittext get the string in there using getText and pass this to an api which will check the username with db to check for similarity and will return a status false if similar user exits and you can show a red underline or red hidden badge to side of the edittext on the basis of this result to notify the user that such a username already exists.

I have an app where I am asking for input a username and password.Right now. It has been changed. Once the user clicks on login in the login menu

I have an app where I am asking for input a username and password.
Right now. It has been changed. Once the user clicks on login in the login menu.
The username should be refilled with a known username and we only ask the user to input password to improve user experience.
Could we use the exist username edit text in my layout file or i have to change to label instead of edit text? I know i can use setText() to populate the username edit text field.
The question is not about saving username (using sharedpreference). what is the best way to
change my code to use ( either edit box or label ).
Please let me know what is the best case to avoid too much change.
Use SharedPreferences to store the usreanme and then everytime you load the layout in your code, check your sharedPreferences and fill the username edittext using setText

How to use Shared-preferences to implement change password functionality in my Android application?

all
i want to create one activity window in which user can change his password.
Like:
Old Password=
New Password=
Retype Password=
Now when the user tries to login for my application the password must be the new one...
so,please give some sample of it. how to achieve it.
Thanks in Advance--
There are various ways to do this.
One way is that you can pop-up a dialog, which contains three EditText for old password, new password and repeat new password.
Some tips:
Set android:password="true" to asterisk the input password
You can check the old password on the lose focus of the EditText

autofill password on edittext

i'm a little blocked with this thing. I want to fill one edittext's password when the user type its login. I have the login and password on one database sqlite. I have read on android developers that it can be done with a AutocompleTextView, but i only want to fill the edittext with its password, nothing else. It Anyone knows how can i do this?¿
Cheers
when you create your activity with the EditText get a handle on it and call setText() with the password from your database.

Categories

Resources