[Gambas-user] How to Disassemble XML/HTML

T Lee Davidson t.lee.davidson at gmail.com
Wed Aug 19 16:37:41 CEST 2020


On 8/19/20 10:18 AM, T Lee Davidson wrote:
> Now since the "publication" element is multidimensional, enumerating over it and printing the value of its elements would cause 
> an error when trying to print the value of "publishedOn" which is itself another Collection[]. This error could be prevented if 
> we check the type of each element [with TypeOf(), Object.Type(), or Object.Is()] and do not try to print anything that is not a 
> string.

I misspoke. "publishedOn" is not a Collection[]. hData is a Collection[], or array of Collections, hence the reason why we 
reference its elements with a numerical subscript. "publishedOn" is a Collection of which one or more of its elements are also 
Collections.

I apologize if that caused any confusion.


-- 
Lee


More information about the User mailing list