怎么获取application.MessageBox()的返回值?分别有哪些返回值?

anytimer 2004-08-12 05:27:58
怎么获取application.MessageBox()的返回值?分别有哪些返回值?请问以下代码对吗?
if application.MessageBox('删除数据'¸'提示',65)=MB_OK then
begin
edit1.Text:='12';
end;
...全文
157 5 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
boatzm 2004-08-12
  • 打赏
  • 举报
回复
hoho
超详细的!
insert2003 2004-08-12
  • 打赏
  • 举报
回复
Delphi帮助
anytimer 2004-08-12
  • 打赏
  • 举报
回复
谢谢
kaguo 2004-08-12
  • 打赏
  • 举报
回复
类型如下
mbYes A button with 'Yes' on its face.
mbNo A button the text 'No' on its face.
mbOK A button the text 'OK' on its face.
mbCancel A button with the text 'Cancel' on its face.
mbAbort A button with the text 'Abort' on its face
mbRetry A button with the text 'Retry' on its face
mbIgnore A button the text 'Ignore' on its face
mbAll A button with the text 'All' on its face
mbNoToAll A button with the text 'No to All' on its face
mbYesToAll A button with the text 'Yes to All' on its face

mbHelp A button with the text 'Help' on its face
kaguo 2004-08-12
  • 打赏
  • 举报
回复
TMsgDlgButtons defines a set of values used by MessageDlg and MessageDlgPos.

Unit

Dialogs

type

TMsgDlgBtn = (mbYes, mbNo, mbOK, mbCancel, mbAbort, mbRetry, mbIgnore, mbAll, mbNoToAll, mbYesToAll, mbHelp);

TMsgDlgButtons = set of TMsgDlgBtn;
const

mbYesNoCancel = [mbYes, mbNo, mbCancel];

mbYesAllNoAllCancel = [mbYes, mbYesToAll, mbNo, mbNoToAll, mbCancel];

mbOKCancel = [mbOK, mbCancel];
mbAbortRetryIgnore = [mbAbort, mbRetry, mbIgnore];
mbAbortIgnore = [mbAbort, mbIgnore];

Description

The TMsgDlgButtons type defines the set of values a button in a message box can have. The TMsgDlgButtons type is used by the MessageDlg and MessageDlgPos functions. The following tables lists the possible values:

Value Meaning

mbYes A button with 'Yes' on its face.
mbNo A button the text 'No' on its face.
mbOK A button the text 'OK' on its face.
mbCancel A button with the text 'Cancel' on its face.
mbAbort A button with the text 'Abort' on its face
mbRetry A button with the text 'Retry' on its face
mbIgnore A button the text 'Ignore' on its face
mbAll A button with the text 'All' on its face
mbNoToAll A button with the text 'No to All' on its face
mbYesToAll A button with the text 'Yes to All' on its face

mbHelp A button with the text 'Help' on its face

In addition, the Dialogs unit defines the following constants for commonly used TMsgDlgButtons values:

Constant Meaning

mbYesNoCancel mbYes, mbNo, and mbCancel
mbYesNoAllCancel mbYes, mbYesToAll, mbNo, mbNoToAll, and mbCancel
mbOKCancel mbOK and mbCancel
mbAbortRetryIgnore mbAbort, mbRetry, and mbIgnore
mbAbortIgnore mbAbort, mbIgnore

5,928

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧