• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Nested:iterate

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am getting No Collection.
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dhamodharan,

What generally is happening with a "no collection" message is that Struts is OK with the syntax of your tags, but when it tries to execute the methods on the beans, it does't find a collection or array as it expects to find.

In the case of your tags, it expects to find a bean named wfdc_RObj in some scope (request, session, etc.) and when it calls the method getWfButtonNames() it expects to find either an array or collection of objects. Similarly, for each object in the collection returned by the getWfButtonNames() method, it executes the method getWfInboxRoutes() and expects to find a collection or array of objects.

Check your data, and verify that there are indeed non-null collections or arrays in these objects.

If these elements could sometimes be null, you will have to surround your iterate tags with <logic:notEmpty> tags.
 
You ought to ventilate your mind and let the cobwebs out of it. Use this cup to catch the tiny ads:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic