this also doesnot solve my problem...
i am posting a sample code... hope it will help ..
first i am adding a widget to the QGridlayout layout using the following lines.
Code:
layout->addWidget(treeWidget,0,0);
setLayout(layout);
then removing that widget and updating and deleting the gridlayout.
Code:
layout->removeWidget(treeWidget);
layout->update();
delete layout;
here i am trying to set the new gridlayout on screen
Code:
layout1->addWidget(checkbox,j,0);
setLayout(layout1);
if i do like this the layout recently set appears over the old one...