lazily initialize pages

Wizard for WPF Forum

Posted 9 years ago by Brent Lamborn
Version: 9.2.0514
Avatar
We have a license for the Wizard control. I noticed the wizard control loads all the pages when it is initialized.

In your documentation it states I can "Lazily initialize pages if needed."

Can you tell me how to lazy initialize the wizard pages? Is it a property on the wizard? I've searched your forums, looked in the docs, etc and cannot find how to do it.

Currently I see the Loaded event being fired on all the child controls for each page. I'm hoping lazy page initialization well solve this so the Loaded event will only fire on the first page in the wizard when my app is first ran.

Can you provide some guidance? Is there a property I can set on the wizard?

Comments (3)

Posted 9 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
You can handle the Wizard.SelectedPageChanging event and initialize the page there before the page is selected and loaded into view.


Actipro Software Support

Posted 9 years ago by Brent Lamborn
Avatar
That's not the problem.

My problem is that when the Wizard is loaded - it also loads the controls in every page. I tested this by hooking into the loaded event of my control that lives inside a WizardPage.

What I want to have happen is when the wizard loads, only the first WizardPage is loaded into memory, instead of all of them.

The Wizard doesn't "lazily initialize pages" by default, so how do I get it to "lazily initialize pages".
Posted 9 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Brent,

Sorry but I don't believe we support specifically what you're asking for at this time.

What we were describing by that text is that you'd need to either keep the page content null and do the technique I had said, or you could just not add later pages to the Wizard until they were ready to be called. The SelectionChanged event allows you to modify any page before it gets displayed.


Actipro Software Support

The latest build of this product (v2019.1 build 0681) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.