[Qt-interest] QWizard method between pages

Andre Somers andre at familiesomers.nl
Mon May 3 22:27:01 CEST 2010


Op 30-4-2010 11:01, Frank Lutz schreef:
> Sadly no but thanks very,
>
> i do have one page before a QLineEdit for Path to copy documents. Than i
> do want to copy these documents into this path and than say on the next
> page thanks for configuration.
>
>
>        QWizard wizard;
>        wizard.addPage(getPathPage());
>        copyDocuments();
>        wizard.addPage(thankyouPage());
>        wizarg.show();
>
> but if i do these on this way, the application will run the methodes
> before an on show(), showing the pages. This is my problem.
>
>    

Look into QWizard::field.
If you register the data you want to transfer from page 1 to page n 
(n>1) as a field, you can access that data later on.

Note that with a little trick, you can even register a wizard page 
itself as a field. All you need to do is add the appropriate property to 
your wizardpage (see the documentation on Q_PROPERTY) and call 
registerField("my interesting piece of data", this, 
"ThePropertyThatContainsMyCoolData", 0)

I hope that helps?

André




More information about the Qt-interest-old mailing list