开发者

DialogResult box default to No?

开发者 https://www.devze.com 2023-01-10 14:47 出处:网络
DialogResult result; result = MessageBox.Show(breakpl[0], \"Move this to confige file?\", MessageBoxButtons.YesNo);
DialogResult result;
result = MessageBox.Show(breakpl[0], "Move this to confige file?", MessageBoxButtons.YesNo);

All 开发者_高级运维I want is for when the box pops up to default to No, there is around 1000 No's and like 10 yes's. So I just want to be able to hit enter and cycle threw them.


Use the MessageBox.Show() overload that takes a MessageBoxDefaultButton argument. Or just invert the question.


There is an overload on MessageBox.Show() to accomplish this. You can read more here

0

精彩评论

暂无评论...
验证码 换一张
取 消