[Qt-interest] QStackedWidget Problem

Sujan Dasmahapatra sdh at lmwindpower.com
Wed Apr 27 16:45:29 CEST 2011


Thanks for you answer shaym I am trying with that let see. Thanks a lot

 

 

Kind Regards,

 

 

Sujan Dasmahapatra
Project Leader, Aero Group
Aero Group

Tel    +91 80 66470248
Mob  

sdh at lmwindpower.com <mailto:%25EMAIL%25> 

 

LM Wind Power Blades

lmwindpower.com

 

Together we capture the wind to power a cleaner world

________________________________

 

This e-mail and any attachments are confidential. If you are not the
named or intended recipient, please notify the sender immediately and do
not disclose the contents to any other person, use it for any purpose,
or store or copy the information in any medium. Any unauthorized
disclosure, use or storage is prohibited and might be unlawful.

From: qt-interest-bounces+sdh=lmwindpower.com at qt.nokia.com
[mailto:qt-interest-bounces+sdh=lmwindpower.com at qt.nokia.com] On Behalf
Of Syam Krishnan
Sent: Wednesday, April 27, 2011 7:24 PM
To: qt-interest at qt.nokia.com
Subject: Re: [Qt-interest] QStackedWidget Problem

 

On 04/27/2011 02:57 PM, Sujan Dasmahapatra wrote: 

Dear Friends

 

class COptWidget : public QWiget

{

                Q_OBJECT

public:

                COptWidget(SomeOtherClass *parent=0);

                ~COptWidget();

};

 

COptWidget *plotopt = new COptWidget(pointerToSomeOtherClass);

QStackedWidget  *curPlot =  new QStackedWidget;

curPlot->addWidget(plotopt);

curPlot->setCurrentWidget(plotopt);

 

 

But with this I am not able to see the plot what am I missing here.
Application crashed at curPlot->addWidget(plotopt);

 

What/where is the parent widget for the stacked widget? It looks like
you need to pass 'pointerToSomeOtherClass' as the parent of the stacked
widget instead of your plot widget.

regards,

Syam

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110427/62173ef9/attachment.html 


More information about the Qt-interest-old mailing list