• <tfoot id='JrR0h'></tfoot>

    • <bdo id='JrR0h'></bdo><ul id='JrR0h'></ul>
    1. <legend id='JrR0h'><style id='JrR0h'><dir id='JrR0h'><q id='JrR0h'></q></dir></style></legend>

      <small id='JrR0h'></small><noframes id='JrR0h'>

      <i id='JrR0h'><tr id='JrR0h'><dt id='JrR0h'><q id='JrR0h'><span id='JrR0h'><b id='JrR0h'><form id='JrR0h'><ins id='JrR0h'></ins><ul id='JrR0h'></ul><sub id='JrR0h'></sub></form><legend id='JrR0h'></legend><bdo id='JrR0h'><pre id='JrR0h'><center id='JrR0h'></center></pre></bdo></b><th id='JrR0h'></th></span></q></dt></tr></i><div id='JrR0h'><tfoot id='JrR0h'></tfoot><dl id='JrR0h'><fieldset id='JrR0h'></fieldset></dl></div>

        Android小部件:如何更改按钮的文本

        Android widget: How to change the text of a button(Android小部件:如何更改按钮的文本)

        <i id='84cdw'><tr id='84cdw'><dt id='84cdw'><q id='84cdw'><span id='84cdw'><b id='84cdw'><form id='84cdw'><ins id='84cdw'></ins><ul id='84cdw'></ul><sub id='84cdw'></sub></form><legend id='84cdw'></legend><bdo id='84cdw'><pre id='84cdw'><center id='84cdw'></center></pre></bdo></b><th id='84cdw'></th></span></q></dt></tr></i><div id='84cdw'><tfoot id='84cdw'></tfoot><dl id='84cdw'><fieldset id='84cdw'></fieldset></dl></div>
          <tbody id='84cdw'></tbody>
            <legend id='84cdw'><style id='84cdw'><dir id='84cdw'><q id='84cdw'></q></dir></style></legend>

                <small id='84cdw'></small><noframes id='84cdw'>

                  <bdo id='84cdw'></bdo><ul id='84cdw'></ul>
                  <tfoot id='84cdw'></tfoot>
                  本文介绍了Android小部件:如何更改按钮的文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  如何在代码而不是 XML 文件中更改 Android 按钮小部件的文本?

                  How can I change the text of an Android button widget within code and not the XML file?

                  推荐答案

                  我能够像这样更改按钮的文本:

                  I was able to change the button's text like this:

                  import android.widget.RemoteViews;
                  
                  //grab the layout, then set the text of the Button called R.id.Counter:
                  RemoteViews remoteViews = new RemoteViews(getPackageName(), R.layout.my_layout);
                  remoteViews.setTextViewText(R.id.Counter, "Set button text here");
                  

                  这篇关于Android小部件:如何更改按钮的文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  How can I use CClistview in COCOS2d Android?(如何在 COCOS2d Android 中使用 CClistview?)
                  cocos2d-android: how to display score(cocos2d-android:如何显示分数)
                  cocos2d 3.x CCButton set the sprite frame image distorted and callback/block not working(cocos2d 3.x CCButton 设置精灵帧图像扭曲和回调/块不起作用)
                  Sqlite database not copied from asset folder Android(Sqlite 数据库未从资产文件夹 Android 复制)
                  SQLite Database Copy Appears Corrupted When Generated by Device and not Emulator(SQLite 数据库副本在由设备而不是模拟器生成时出现损坏)
                  Android file copy(安卓文件拷贝)
                  • <bdo id='Mxoe4'></bdo><ul id='Mxoe4'></ul>

                            <tbody id='Mxoe4'></tbody>
                          <tfoot id='Mxoe4'></tfoot>
                          1. <small id='Mxoe4'></small><noframes id='Mxoe4'>

                            <legend id='Mxoe4'><style id='Mxoe4'><dir id='Mxoe4'><q id='Mxoe4'></q></dir></style></legend>
                            <i id='Mxoe4'><tr id='Mxoe4'><dt id='Mxoe4'><q id='Mxoe4'><span id='Mxoe4'><b id='Mxoe4'><form id='Mxoe4'><ins id='Mxoe4'></ins><ul id='Mxoe4'></ul><sub id='Mxoe4'></sub></form><legend id='Mxoe4'></legend><bdo id='Mxoe4'><pre id='Mxoe4'><center id='Mxoe4'></center></pre></bdo></b><th id='Mxoe4'></th></span></q></dt></tr></i><div id='Mxoe4'><tfoot id='Mxoe4'></tfoot><dl id='Mxoe4'><fieldset id='Mxoe4'></fieldset></dl></div>