In renderChart there is a line updating the chart panel like this

PartialPageRequestHandler.add(chartPanel);

On Wed, Apr 24, 2019 at 8:06 PM Sibgha Nazir <sibgha...@gmail.com> wrote:

> I make the call like this
>
>     @Override
>
>     *public* *void* renderHead(IHeaderResponse response)
>
>     {
>
>         *super*.renderHead(response);
>
>
>
>         Optional<AjaxRequestTarget> target = RequestCycle.*get*
> ().find(AjaxRequestTarget.*class*);
>
>
>         *if* (!target.equals(Optional.*empty*()))
>
>             renderChart(target.get());
>
>     }
>
> On Wed, Apr 24, 2019 at 7:00 PM Martin Grigorov <mgrigo...@apache.org>
> wrote:
>
>> Hi,
>>
>> On Wed, Apr 24, 2019 at 5:08 PM Sibgha Nazir <sibgha...@gmail.com> wrote:
>>
>> > Hello wicket developer,
>> >
>> > I am facing the following exception on re-rendering a wicket panel using
>> > the code
>> >
>> >
>> >
>> >           iPartialPageRequestHandler.add(chartPanel);
>> >
>>
>> In which method of your code do you make that call ?
>> How do you get a reference to iPartialPageRequestHandler? Is it passed as
>> a
>> parameter to the method by Wicket or do you look it up by using
>> RequestCycle.find(Class) ?
>>
>>
>> >
>> > java.lang.IllegalStateException: A partial update of the page is being
>> > rendered, component [ChartPanel [Component id = chart-container]] can no
>> > longer be added
>> >
>> > It renders it perfectly the first time. But I want to call this again
>> and
>> > again when user clicks refresh button. What does this mean?
>> >
>> > Best Regards,
>> > Sibgha Nazir
>> >
>>
>

Reply via email to