This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes Struts and the fly likes bean tag problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "bean tag problem" Watch "bean tag problem" New topic
Author

bean tag problem

shukla raghav
Ranch Hand

Joined: Aug 03, 2008
Posts: 200
i dont know why the folowing bean tag is not working

struts.xml



DoBeanTags.jsp



BeanTestAction.java



DoBean.jsp



SelectBean.java



David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Please see ItDoesntWorkIsUseless and TellTheDetails.

And this.
shukla raghav
Ranch Hand

Joined: Aug 03, 2008
Posts: 200
First all ! Mistake Accepted, i am really sorry for not framing my question properly.

Expected Output : Display the value of property itm i.e. Washing Machine from the SelectBean class. in DoBean.jsp
Actual Output : blank screen

The link that you ahve sent is very useful i thnk i have got my answer.OGNL is a bit confusing sometimes when it comes to retrieving values.

Every time i am adviced, for my mistakes, using such wonderful links i am amazed to see such an organized functioning of java ranch. Great Work !!! It is to Java Programmers what Google is to general public.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Glad you figured it out :)

In this case it isn't really OGNL itself that's the issue, but the lack of consistency in S2 regarding when to use the OGNL escape %{} and when it's implied. In this case, it's implied, but not necessarily obvious... Most S2 developers seem to prefer *always* using the OGNL escape--it makes things easier to understand.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: bean tag problem
 
Similar Threads
Error setting the expression with value [Ljava.lang.String;@1d05b0a
WARNING: Could not find action or result
java.lang.NullPointerException
method not executing in action class
problem with the bean tag