TrainBeaser for iPhone
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes setDynamicAttribute not being invoked Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Professional Certification » Web Component Certification (SCWCD/OCPJWCD)
Reply Bookmark "setDynamicAttribute not being invoked" Watch "setDynamicAttribute not being invoked" New topic
Author

setDynamicAttribute not being invoked

David Pantale
Ranch Hand

Joined: Mar 16, 2010
Posts: 30
Hi there, I can't seem to get the setDynamicAttribute method to work properly. I can get the application to print out the options but not the attributes. Below is my code (note I've been playing with it by commenting and uncommenting parts) :


the jsp:


the tld:

As I said, I can get it all to work except printing out the size attribute, to do that I have to put "out.print(String.format(ATTR_TEMPLATE, "size", this.size));" into my code.

Can anyone see why the setDynamicAttribute method is not being called by the container?

Thanks
Dave
Christophe Verré
Marshal

Joined: Nov 24, 2005
Posts: 14361


There's a typo here, it should be "dynamic-attributes".


[SCBCD Wall of Fame] [My Blog]
All roads lead to JavaRanch
Help Japan. Make a donation.
Jayavardhan geepi
Ranch Hand

Joined: Jul 21, 2010
Posts: 63
Hi..

I have the same problem even after checking all typos.

I'm getting jasperexception at the line of tag invocation.

It says root cause as :
java.lang.NullPointerException
customtag.simpletag.TestTag.<init>(TestTag.java:20)
org.apache.jsp.JSP.SimpleTagTest_jsp._jspx_meth_t_005fTest_005f0(SimpleTagTest_jsp.java:96)


Can someone help ... What might went wrong..?
 
IntelliJ Java IDE
 
subject: setDynamicAttribute not being invoked
 
Threads others viewed
Tutorial on Dynamic Attributes
HFSF - page 547 - ATTR_TEMPLATE?
Doubt in JSP Custom tags (Simple Tag) in Dynamic Drop Down
unable to access the attribute in any of the container scope
Doubt on page 547 HFSJ
developer file tools

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture