以编程方式设置按钮文字 [英] Programmatically set button text
本文介绍了以编程方式设置按钮文字的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何在Clarion中以编程方式设置按钮文本?显然,我可以使用设计器界面在控件上设置默认文本,但是我希望能够更改代码中的显示文本.有办法吗?
我尝试了以下操作,但没有任何效果,甚至没有编译:
?Button1:Text = 'Test'
解决方案
您可以使用PROP:text
,以编程方式在Clarion中设置按钮的文本:
?Button1{PROP:Text} = 'Test'
我是根据我在此处的另一个问题进行的研究得出的.
How do you programmatically set the button text in Clarion? Obviously I can use the designer interface to set the default text on a control, but I want to be able to change the display text in the code. Is there a way to do that?
I've tried things like the following, but nothing has worked or even compiled:
?Button1:Text = 'Test'
解决方案
You can programmatically set the text of a button in Clarion using PROP:text
:
?Button1{PROP:Text} = 'Test'
I figured this out based on some research from another question I had here.
这篇关于以编程方式设置按钮文字的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文