Point object conflict

Hi guys, I had troubles trying to create a DesignScript.Geometry.Point in my Python Script. I noticed that the problem comes when I import the RevitAPI (Autodesk,Revit.DB). I have tried to code Autodesk.DesingScript.Geometry.Point, instead of just Point but that also doesnt work. How would you handle this?

Either qualify your class:

pt = Autodesk.DesignScript.Geometry.Point.ByCoordinates(0.0, 0.0, 0.0)

…or use an alias in your import statements:

import clr
from Autodesk.DesignScript.Geometry import *
from Autodesk.DesignScript.Geometry import Point as ProtoPoint

import Autodesk
from Autodesk.Revit.DB import *

pt = ProtoPoint.ByCoordinates(0.0, 0.0, 0.0)

You can also declare an alias like this:

import Autodesk.DesignScript.Geometry.Point as ProtoPoint

1 Like

This didnt worked for me. Ii tells me “Autodesk” is not defined.

This was the absolute solution. Thanks to you so much =)