Rectangle.ByCornerpoints can't work?

I use python code to get points, and I want to create rectangle.
But It show:
Warning: One or more of the input types are not matching. Couldn’t find a version of ByCornerPoints that takes arguments of type (__array)

How can I feed points?@mellouze


I guess you are not feeding points to Rectangle.ByCornerPoints. You might want yo check the type of data.

They are not points. you need to use a coordinates after your python node

Create points as I showed you in the example above. You can use the same syntax in a Python Node.

1 Like

If UX1,UY1, etc. are of type double, i guess you just have to replace :

U1 = XYZ(UX1, UY, UZ1)


U1 = Point.ByCoordinates(UX1,UY1,UZ1)

and so on.

I tried. @mellouze But It show:
Warning: IronPythonEvaluator.EvaluateIronPythonScript operation failed.
Traceback (most recent call last):
File “”, line 65, in
AttributeError: ‘type’ object has no attribute ‘ByCoordinates’


To be honest, i don’t know. Have you imported the corresponding Dynamo functions ? What version of Dynamo are you using ?

import clr
from Autodesk.DesignScript.Geometry import *

My version is 1.2

It’s Okay now

Maybe I import too much things.
Thanks~ @mellouze

As far as i understand from the comment of @Thomas_Mahon (topic below), that could give problems.

For the rest, interesting topic,learned some new things :thumbsup:

Kind regards,