EDITTEXT不节能投入的ListView动态长度 [英] Dynamic length of Listview of Edittext not saving input
问题描述
我的箱子的EditText列表视图。我也有一个按钮来添加一个新行到列表中,因此,其列表的长度是动态的。
I have listview of edittext boxes. I also have a button to add a new row into the list, thus, the list length is dynamic.
然而,当我输入的文本进入的EditText和preSS的添加按钮,我的输入消失。我认为,当我添加了一个新行到列表中输入我不会捕获。我该如何拯救我的输入,所以当我改变行的数量,我的文字依然?
However, when I entered text into the edittext and press the add-button, my input disappears. I think my input is not captured when I added a new row into the list. How can I save my input so when I change the amount of rows, my text remains?
推荐答案
您的想法是好的,但你需要坚持的EditText上的数据。尝试添加textwatcher每个的EditText和保存每个EditText上的文本数组或东西
Your idea is fine, but you need to persist the edittext's data. Try adding textwatcher to each edittext and save the text for each edittext in a array or something
这篇关于EDITTEXT不节能投入的ListView动态长度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!