hello everyone!
i need to creat a surface to calculate its area,so i created a list of points.
But in sometimes end of list’s point is not needed.
so i tried if function in code block,but the returned list was not expected.
SOLVED
use NUMBER(WITHOUT LIST) in the if function
like this
===============================================
slope_Z =
String.ToNumber(DSCore.String.FromObject(Point.Z(List.GetItemAtIndex(intersect_List,[5]))));
alignment_Z =
String.ToNumber(DSCore.String.FromObject(Point.Z(List.GetItemAtIndex(intersect_List,[6]))));
a = slope_Z-alignment_Z;
remove_Pt = [Imperative]
{
if (slope_Z<alignment_Z){
return List.GetItemAtIndex(intersect_List,[0,1,2,3,4,5]);
}
else{
return intersect_List;
}
};