11-28-2022 10:00 AM
Im just trying to learn about classes. Here is a simple program that is throwing an error on the class down-cast -
Why is this error happening? The Parent-Child hierarchy is correct. I created "Method 1.vi" of the Parent using the Dynamic Dispatch template and set it to "must override". The child "Method 1.vi" is a VI for Override of the parent. version of Method 1.vi.
Solved! Go to Solution.
11-28-2022 10:33 AM
A Parent is not a Child. So if you initialized as a Parent, you cannot downcast to a Child. If you started with a Child, you can upcast to a Parent and later downcast to a Child.
12-12-2022 08:33 AM
I get it now. Thanks for helping me.