0

在 Windows Mobile PocketPC/Pro 中,您可以通过设置 MinimizeBox = 'false' 来指定使用最小化按钮来关闭表单(触发 Closing 事件等)。在智能手机上,后退按钮的使用方式与 PocketPC 表单角落中的 X 相同,但我似乎找不到明显(或不太明显)的功能来允许我将其行为更改为“关闭” ,而不是“最小化”。

关于如何去做的任何线索?

4

1 回答 1

2

This is an article on capturing the Back button. There is also a sample in the SDK.

In my opinion however, you shouldn't override its functionality. Another approach you could follow is to start a timer on the OnDeactivate handler of your form. Assuming that your main form isn't hidden by another form in your application, this will be called when your application goes in background. If you have more than one form, more work is needed to capture the event of going in the background. If the user, doesn't bring your application at the foreground in a reasonable amount of time, then close it.

于 2009-05-13T22:02:14.513 回答