You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Jayakrishnan KR <ja...@gmail.com> on 2008/01/24 11:25:34 UTC

Tiles 2.0.5 Error : java.lang.NoSuchMethodError: org.apache.tiles.TilesContainer.render

Hi,
I am using Tiles 2.0.5 with Struts 2.0.6 in tomcat 6.0.14.. I am
congfiguring the tiles thruougdefining it as servlet in the web.xml as
follows :
<servlet>
<servlet-name>tiles</servlet-name>
<servlet-class>org.apache.tiles.web.startup.TilesServlet</servlet-clas s>
<init-param>
<param-name>definitions-config</param-name>
<param-value>/WEB-INF/tiles.xml</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet> .
and using the result type as tiles default in struts.xml as follows:
<result-types>
<result-type name="tiles" class="org.apache.struts2.views.tiles.TilesResult"
default="true" />
</result-types>.
I have tiles-api-2.0.5, tiles-2.0.5-core, tiles-2.0.5-jsp jars in my lib.
After that i deployed that in tomcat and trying to acces the page from
index.jsp file, it throws me the error as follows :
SEVERE: Servlet.service() for servlet default threw exception
[java] java.lang.NoSuchMethodError:
org.apache.tiles.TilesContainer.render(Ljava/lang/Object;Ljava/lang/Object;Ljav
a/lang/String;)V
[java] at org.apache.struts2.views.tiles.TilesResult.doExecute(
TilesResult.java:104)
[java] at org.apache.struts2.dispatcher.StrutsResultSupport.execute(
StrutsResultSupport.j ava:178)
[java] at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvo
cation.java:343)
.......................................................

I am attaching the project file with this. I removed lib coz of size
concern.
So please help me to solve this issue .

Thanks in advance,
JK

On Jan 24, 2008 3:24 PM, strutting <la...@gmail.com> wrote:

>
> Hi All,
>
> I'm new in struts and I can't solve a little problem... I'm trying to
> populating a tree with data from a database, and I'd like to do that using
> the iterator tag. My code is the following one:
>
> <s:tree theme = "ajax" id = "root" label = "Reservations">
>        <s:iterator value = "reservations">
>                <s:treenode theme = "ajax" label="Reservation ID:
> <s:property value =
> "rid"/>">
>                        <s:treenode theme = "ajax" label="Is a
> pre-reservation? : <s:property
> value = "isPre"/>"/>
>                        <s:treenode theme = "ajax" label="Services">
>                                <s:iterator value = "services">
>                                        <s:treenode theme = "ajax"
> label=<s:property value="sid"/> />
>                                        <s:treenode theme = "ajax"
> label="Automatic activation: <s:property
> value="automaticActivation"/>/>
>                                </s:iterator>
>                        </s:treenode>
>                </s:treenode>
>        </s:iterator>
>    </s:tree>
>
> The definition of the data type reservations:
>
> Reservation[] reservation
>     int rid;
>     boolean is Pre;
>     Service[] services;
>          int sid;
>          boolean automaticActivation;
>
> The problem is the LABEL field that only allows Strings. I'd like to fill
> this field with the evaluation of the iterator property.
>
> Can someone help me? I've looking for this in many tutorials, forums...
> but
> I haven't found anything...
>
> Thanks in advance!
> --
> View this message in context:
> http://www.nabble.com/Combining-the-iterator-tag-with-the-tree-tag-%28problem-with-label-field%29-tp15061806p15061806.html
> Sent from the Struts - User mailing list archive at Nabble.com<http://nabble.com/>
> .
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

Re: Tiles 2.0.5 Error : java.lang.NoSuchMethodError: org.apache.tiles.TilesContainer.render

Posted by Jayakrishnan KR <ja...@gmail.com>.
thanks for ur update antanio.


On 1/24/08, Antonio Petrelli <an...@gmail.com> wrote:
>
> 2008/1/24, Jayakrishnan KR <ja...@gmail.com>:
> >
> > I am using Tiles 2.0.5 with Struts 2.0.6
>
>
> Struts 2.0.6 is not compatible with Tiles 2.0.5.
> Please upgrade to Struts 2.0.11.
>
> Antonio
>

Re: Tiles 2.0.5 Error : java.lang.NoSuchMethodError: org.apache.tiles.TilesContainer.render

Posted by Antonio Petrelli <an...@gmail.com>.
2008/1/24, Jayakrishnan KR <ja...@gmail.com>:
>
> I am using Tiles 2.0.5 with Struts 2.0.6


Struts 2.0.6 is not compatible with Tiles 2.0.5.
Please upgrade to Struts 2.0.11.

Antonio