Given this:
set theSizeList to {{theSize:"cXS", quantity:0}, {theSize:"cS", quantity:36}, {theSize:"cM", quantity:65}, {theSize:"cL", quantity:76}, {theSize:"cXL", quantity:40}, {theSize:"cXXL", quantity:20}, {theSize:"cXXXL", quantity:7}, {theSize:"cXXXXL", quantity:1}}
How do I return a list of every size whose quantity is not 0?
This doesn’t work:
every item of theSizeCells whose (quantity of it ≠"0")
--> "Can't get {{theSize:\"cXS\", quantity:0}, {theSize:\"cS\", quantity:36}, {theSize:\"cM\", quantity:65}, {theSize:\"cL\", quantity:76}, {theSize:\"cXL\", quantity:40}, {theSize:\"cXXL\", quantity:20}, {theSize:\"cXXXL\", quantity:7}, {theSize:\"cXXXXL\", quantity:1}} whose quantity ≠0."
Still a little shaky with this key value business.