![](/img/trans.png)
[英]different of setText(CharSequence,TextView.BufferType) and setText(CharSequence)
[英]Android TextView.BufferType values
初學者Android開發人員在這里。
我正在嘗試使用setText()將EditText設置為整數,但是我遇到了一些麻煩。
int min = 10;
minEditText.setText(min + "");
這不會將min的值設置為EditText小部件。 我做了一些研究,發現:
setText(CharSequence text, TextView.BufferType type)
有人可以指導我如何使用它,什么是BufferType以及設置EditText小部件的文本的最佳方法是什么?
非常感謝。
嘗試minEditText.setText(“” + min);
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.