I see in the docs that a method can return a user defined type. I have been experimenting with this, but can't quite figure out how to access the individual elements of the UDT. Here's an example:
In the above example I would expect to access elem6 in the type by calling my object like MyObj.TestMethod.elem6, but this doesn't seem to work. Can someone tell me the correct way to read back UDT data embedded in an object.
My goal is to have this as read-only data so I first tried the Property, but it doesn't work using the Method either. At least the way that I was trying
I was trying ObjectName.Method/Property.UDT_Element
I am new at this object stuff, so forgive me... But I am beginning to see great potential here!
Code:
Type TestType elem1 as long elem2 as long elem3 as bit * 1 in Byte elem4 as bit * 1 elem5 as bit * 6 elem6 as asciiz * 20 End Type ... Method TestMethod As TestType Method = TestTypeVar End Method ... Property Get TestProp As TestType Property = TestTypeVar End Property ...
My goal is to have this as read-only data so I first tried the Property, but it doesn't work using the Method either. At least the way that I was trying

I was trying ObjectName.Method/Property.UDT_Element
I am new at this object stuff, so forgive me... But I am beginning to see great potential here!
Comment