Great Reply. thanks Gerolf. I'll check it out and let you know.

f(t)


On 8/30/07, Gerolf Seitz <[EMAIL PROTECTED]> wrote:
>
> i usually do it like this:
>
> Panel panel = new StandardPanel(m_cPanelToLoad.getId(), "ThisForm",
> "ThisTitle");
> m_cPanelToLoad.replaceWith(panel);
> m_cPanelToLoad = panel;
> target.addComponent(m_cPanelToLoad);
>
> if you don't want the "language panel" to decide which component should be
> created, but rather let the parent of all panels manage the replacements,
> you could take a look at Thies Edelings blog entry here:
> http://blog.ehour.nl/index.php/archives/18
>
> gerolf
>
> On 8/30/07, Francisco Diaz Trepat - gmail <[EMAIL PROTECTED]>
> wrote:
> >
> > Hi, I have to update the center of the page on a simple site. An earlier
> > version of this app use frames.
> >
> > I want to use panels and ajax. I did this in the prototype:
> >
> > I have a container, that holds the panels (A or B or C or "you catch my
> > drift" >_> ).
> >
> > private StandardPanel m_cPanelToLoad;
> >
> > //Construct the language panel
> >       add(new AjaxLink("link1") {
> >          public void onClick(AjaxRequestTarget target) {
> >
> >             container.remove(m_cPanelToLoad);
> >
> >             m_cPanelToLoad = new StandardPanel("panelContent",
> "ThisForm",
> > "ThisTitle");
> >
> >             container.add(m_cPanelToLoad);
> >
> >             target.addComponent(container);
> >
> >          }
> >       });
> >
> > It doesn't seem so right. but works fine...
> >
> > Any sugestions? avoid, "If it works don't fix it", please, I hate it...
> > :-)
> >
> > f(t)
> >
>

Reply via email to