Android Question multiple edittext in scrollview

imadreem

New Member
Licensed User
Hello everyone


i am using multiple edittext in a scrollview
when checking for enterpressed or gotfocus i always get the data of the last edittext in the scrollview not the one i am using

Please help
 
How do you add the EditText views in the ScrollView ?
1689854370040.png

above code is for defining edittext

1689854497083.png

and here i retrive it when enter is pressed
 
Upvote 0
Use code tags </> to display code.

Something like that.
[CODE lang="b4x" title="B4X"]Dim edtxt(listitems.size) As B4XView 'number of edittext
For i = 0 To listitems.size -1 'your list
Dim myEdTXT As EditText
myEdTXT.Initialize("etView")
edTXT(i) = myEdTXT
edtxt(i).Tag = i
Next[/CODE]
 
Upvote 0
Use code tags </> to display code.

Something like that.
[CODE lang="b4x" title="B4X"]Dim edtxt(listitems.size) As B4XView 'number of edittext
For i = 0 To listitems.size -1 'your list
Dim myEdTXT As EditText
myEdTXT.Initialize("etView")
edTXT(i) = myEdTXT
edtxt(i).Tag = i
Next[/CODE]
thank you Zed
i used your code and it is working perfect
 
  • Like
Reactions: zed
Upvote 0
Back
Top