【发布时间】:2016-12-26 06:47:47
【问题描述】:
我在FlowLayoutPanel 中有许多带有不同文本的按钮,我想找到带有特定字符串的按钮。
我目前正在这样做:
Dim str as String = 'some text
For each btn as Button in FlowLayoutPanel.Controls
If btn.Text = str then
'do something with btn
End If
Next
有可能做这样的事情吗?
Dim str as String = 'some text
Dim btn as Button = FlowLayoutPanel.Controls.Button.Text with that string
'do something with btn
【问题讨论】: