How do I define a declare expression in the top level class on a property in a polymorphic subclass?
I have a work object which I'll refer to as pyWorkPage, and I have properties in polymorphic subclasses that I need to put declare expressions on. The structure looks like this:
pyWorkPage
- Automobiles [page]
-- Category(1) [page list]
--- Jeep (text)
--- RangeRover (text)
--- Toyota (text)
-- Category(2)
--- Mustang (text)
--- Camaro (text)
etc
I need to define a declare expression in pyWorkPage on ".Jeep". The problem is I can't create the expression with a context of .Automobiles.Category(1) because I have no guarantee that Category(1) will always be "off road" vehicles. The first polymorphic category could become a new one such as "trucks" depending on how the vehicles are being categorized. How do I define a declare expression in the top level class on a property in a polymorphic subclass when the index is unknown?
**RESOLVED
The work around for this is to create the declare expression in the polymorphic subclass (the Catgory(1) subclass in this example).