简体   繁体   中英

Disable or Hide Save/Print Preview Dialog popups

I'm working with an ActiveX control placed on a winform. I'd when the user tries to save or print, it will always show a dialog box first; I'd like to either immediately close the dialog box or keep it from displaying in the first place.

The control in question does not raise any events that would let me know what button they pushed, so I can't really cancel it out by looking for an "on_print" notification.

I ended up just sending escape via SendKey() whenever WM_ENTERIDLE was processed and that did the job. Dirty hack, but it worked.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM