You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by John <jo...@jak.com> on 2007/01/12 20:58:50 UTC
[Tobago] Problems with Tobago.reloadComponent with onclick
When I use the onclick as follows (per a previous message from Volker),
I get the following error in IE.
<t:toolBarCommand label="Refresh" action="#{quarantine.refresh}"
image="images/view-refresh.jpg" tip="Refresh list of quarantined
messages" id="quarantineCmdRefresh"
onclick="Tobago.reloadComponent('messageCount', '@autoId')"/>
Line: 582
Char: 7
Error: Object doesn't support this property or method
Code:0
If I remove the onclick part it works fine (but of course I can't use
the AJAX dynamic updating of my tx:in component
Thanks,
John
Re: [Tobago] Problems with Tobago.reloadComponent with onclick
Posted by Bernd Bohmann <be...@atanion.com>.
Hello John,
which version of tobago are you using?
Regards
Bernd
John wrote:
> When I use the onclick as follows (per a previous message from Volker),
> I get the following error in IE.
>
> <t:toolBarCommand label="Refresh" action="#{quarantine.refresh}"
> image="images/view-refresh.jpg" tip="Refresh list of quarantined
> messages" id="quarantineCmdRefresh"
> onclick="Tobago.reloadComponent('messageCount', '@autoId')"/>
>
>
> Line: 582
> Char: 7
> Error: Object doesn't support this property or method
> Code:0
>
>
> If I remove the onclick part it works fine (but of course I can't use
> the AJAX dynamic updating of my tx:in component
>
> Thanks,
> John
>
Re: [Tobago] Problems with Tobago.reloadComponent with onclick
Posted by Volker Weber <we...@googlemail.com>.
Hi John,
which version of tobago?
the onclick="Tobago.reloadComponent(<clientId>, '@autoId')"/> should
work (afaik), but is not the intended way to code ajax reload (this
was a interim solution).
anyway, the 'messageCount' is not a valid clientId, and tc:in is not
ajax reloadable.
the clientId is build from ids of namingcontainers, at least tc:page,
and the id of the component, so a valid clientId has at last on colon.
to reload the content of a tx:in you can surround it by a tc:panel e.g
(in the intended way):
<tc:page id="page"/>
<tc:panel id="panel">
<tx:in .../>
</tx:panel>
<tc:button ...>
<tc:attribute name="renderedPartially" value=":page:panel"/>
</tc:button>
</tc:page>
see the colon before 'page:panel' to make the clientId absolute.
regards,
Volker
2007/1/12, John <jo...@jak.com>:
>
>
> When I use the onclick as follows (per a previous message from Volker), I
> get the following error in IE.
>
> <t:toolBarCommand label="Refresh" action="#{quarantine.refresh}"
> image="images/view-refresh.jpg" tip="Refresh list of quarantined messages"
> id="quarantineCmdRefresh" onclick="Tobago.reloadComponent('messageCount',
> '@autoId')"/>
>
>
> Line: 582
> Char: 7
> Error: Object doesn't support this property or method
> Code:0
>
>
> If I remove the onclick part it works fine (but of course I can't use the
> AJAX dynamic updating of my tx:in component
>
> Thanks,
> John