dahall / AeroWizard

Library for easy creation of custom and Aero Wizards. Aero Wizard strictly follows Microsoft guidelines and uses Visual Styles to get visual theming.
MIT License
112 stars 32 forks source link

Commit event not fired when Finish is clicked #36

Closed dahall closed 5 years ago

dahall commented 5 years ago

Commit event is not fired when Finish is clicked. Is this by design or a bug?

Originally posted: 2011-03-12T05:57:34

dahall commented 5 years ago

Well, technically I could say it is either. I think it does make sense to be consistent on every page and fire the Commit event. However, I'm not sure how to handle the condition where Commit fails when its the last page. What are your thoughts? Would you share your use case?

Originally posted: 2011-03-12T18:24:33

dahall commented 5 years ago

Thank you for your fast reply.

Well, I have a wizard to help the user to generate a report. When the user clicks the Finish button, it would generate the report. I tried to use the Commit event of the page and did not know about the Finished event of the control at the time. Now, the program generates the report during the Finished event.

My suggestion is to trigger the Commit event on the last page. If the Cancel property is set to true, then don't trigger the Finished event and don't close the form. Otherwise, trigger the Finished event and close the form.

Originally posted: 2011-03-13T15:24:15

dahall commented 5 years ago

This has been implemented in source code release 56509 and today's 1.0 download update.

Originally posted: 2011-03-14T11:59:54