MaterialDesignExtensions icon indicating copy to clipboard operation
MaterialDesignExtensions copied to clipboard

Reset Current Step After Cancelled

Open allenlooplee opened this issue 4 years ago • 0 comments

Hello,

I'm currently using a Stepper within a flyout from MahApps.Metro. When a user clicks the cancel button on the StepButtonBar, the flyout will be closed. But next time when the user opens the flyout, the Stepper will show the step that was shown before closed last time instead of the first step. I wonder if there's any easy way to reset the Stepper to its first step when cancel command is triggered.

Currently I tried to handle CancelNavigation event of Stepper and call GoToStep of its controller to do this reset, and it works. Next I'm going to create an attached property to make this easier. But I still want to know if I'm missing something that I'm not aware of.

Thanks/Allen

allenlooplee avatar Jul 06 '21 09:07 allenlooplee