I have a parameter calculating an area of an intersect. The
objects in the intersect can change dynamically (via EKL) and it
may happen that there is be no intersect in some situations.
In such cases CATIA gives an error which is undesirable. To prevent
this i try to foresee these use cases and disable the
intersect object via EKL. That part works in terms of giving no
errors.
Unfortunately the area() function is complaining if the intersect object is invalid. It seems the object loses the "Surface" type - it is a "Feature" and that triggers an error of the area().
Im looking for any way to handle it or a workaround to avoid errors.
I tried:
- move area() to a different reaction which is triggered only when
the intersect object is valid - it does not help.
- a dummy surface and "assemble()" it with the intersect - that
also doesnt work, this time because of the assemble function
expecting either curves or surfaces.
- i can fake the intersect objects so that the intersect is still
valid in these use cases and hide those fake objects from users but
i really dont want to go that route.
I hope there is some way to catch / disable errors like that or make the intersect stay a surface, just 0mm2 surface.