David Xiao wrote: > I receive following error: TypeError: len() of unsized object > I am quite sure that pics is with results, it's not empty. I guess > maybe there should be another function to test iterable list's > length(), but what could be?
For simplicity I assumed "pics" is just a list of URLs. If you have a SQLObject SelectResult, you need to convert it to such a list first, using something like: pics = [p.url for p in pics] Or, if you want to use the SelectResult directly you can determine the number of pics as pics.count() instead of using len(pics). Then you will probably have to write something like pics[i].url instead of pics[i]. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears?hl=en -~----------~----~----~----~------~----~------~--~---

