- UID
- 10108
- 积分
- 5956
- 精华
- 贡献
-
- 威望
-
- 活跃度
-
- D豆
-
- 在线时间
- 小时
- 注册时间
- 2002-9-17
- 最后登录
- 1970-1-1
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?立即注册
×
Detecting if cancel was pressed in DCL dialog boxes By Gopinath Taget
Its pretty rare to encounter DCL dialogs in AutoCAD now a days but if you do, here is some info that you might find useful.
Lets say you are using command reactors to detect when certain commands are cancelled, yet when the command has a dialog box, there is no difference if a user presses Cancel or OK (only the Editor reactor commandEnded() is called). So, how can you detect the difference between OK and Cancel when selected from a dialog box?
This a known issue with the AutoCAD DCL dialog implementation. A workaround for commands that use the DCL dialog is to read the AutoCAD system variable DIASTAT in the commandEnded() function. DIASTAT is set to 0 if the user has pressed Cancel, and set to 1 if the user presses OK. For AutoCAD MFC based commands, there is no solution at this time.
|
评分
-
查看全部评分
|