StructKeyExists Question
Hi,
I have a stuct that looks like this:
If I need to display the attributes array. This works:
<cfoutput>#shipment_response.data.rates["9"].attributes[1]#</cfoutput>However sometimes the Array is [empty]. How can I determine if it exists? I tried:
<cfif StructKeyExists(shipment_response.data.rates["9"], "attributes[1]")>
<cfoutput>#shipment_response.data.rates["9"].attributes[1]#</cfoutput>
</cfif>It doesn't execute the cfoutput either way (exists or empty). What am I doing wrong with StructKeyExists?
Thanks in advance for any suggestions!
Gary
