本文介绍了如何从textBox调用MessageBoxButtons.YesNo对话框中的YesNo按钮的事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的朋友:

当我在textBox注销中写入内容时,我只有一个textBox,那时候我调用DialogResult button==messageBox.show("","",MessageBoxButton.YesNo),当我单击yes或no按钮时,出现在我的对话框中的yes按钮和no按钮将执行操作.

我的问题是:当MessageBoxButton.YesNo对话框出现时,我想通过我的textBox文本控制这些YesNo按钮.
示例:当我在textBox.text="yes"中进行写入时,是从MessageBoxButton.YesNo对话框发生的按钮事件,或者如果我在textBox.text="no"中进行写入,则没有按钮事件会执行.我搜索了Google,但没有找到可接受的解决方案.
希望你有身体帮助我.
谢谢.

Dear Friends:

I have one textBox when i write in textBox logOff, that time i call to DialogResult button==messageBox.show("","",MessageBoxButton.YesNo) and it appear to me dialogBox which have yes button and no button when i click yes or no button then action will perform.

My Question is that:when MessageBoxButton.YesNo Dialog appears that time i want to control these YesNo button through my textBox text.
Example: When i write in textBox.text="yes" yes button event occurred from MessageBoxButton.YesNo dialog or if i write in textBox.text="no" No button event become execute. I search Google but i did not find acceptable solution.
Wish you some Body help me.
Thank you.

推荐答案



这篇关于如何从textBox调用MessageBoxButtons.YesNo对话框中的YesNo按钮的事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-24 14:47