Maybe I am doing something wrong but imo the below code should work.
-
Create a testProperty in View1
-
Put this code in a second iOSView (for example View2)
dim test() as iOSView
test.Append(new view1)
test(0).testProperty = "Test" // <- this does not work. Why?
It now seems you cannot access the testProperty
BTW the same code can be put in the View1. Same thing happens.
Bob_Keeney
(Bob Keeney)
2
iOSView is the super for View1 so when you do:
test(0).testProperty = “Test” you get the failure because test(0) is an array of iOSView and NOT view1.
Try:
View1(test(0)).testProperty = "Test"
This will cast the super to your subclass. For completeness you might want to do the following:
if test(0) isa View1 then
View1(test(0)).testProperty = "Test"
end
Hopefully that makes sense.