Search the Community
Showing results for tags 'python api'.
-
Hi, I' using the following code to create a pitched roof in Vectorworks, but always got a pop-up error "Could not create roof, probably not enough walls". Does anyone know why? # Define the coordinates for the roof base roof_vertices = [(0, 3000), (5000, 3000), (5000, 0), (0, 0)] # Create a polygon for the roof base vs.Poly(*roof_vertices) poly_h = vs.LNewObj() # Create a pitched roof using the polygon as the base hroof = vs.CreateRoof(False,0,0,0,0) num = vs.GetVertNum(poly_h) for i in range(num): i = i+1 vertex = vs.GetPolylineVertex(poly_h,i)[0] slope=30 eave_overhang=500 eave_height=3000 vs.AppendRoofEdge(hroof, vertex, slope, eave_overhang, eave_height) bearingInsetDistance = 10 roof_thickness=300 vs.SetRoofAttributes(hroof, False, bearingInsetDistance, roof_thickness, 1, 0) # error after excuting this line vs.SetClass(hroof, "Roofs")
-
Python Language Exception Control - SyntaxError EOL while scanning literal
twk posted a question in Troubleshooting
https://forum.vectorworks.net/index.php?/topic/44990-syntaxerror-eol-while-scanning-literal/ Apparently it's a Vectorworks Python API bug. Can we please have this fixed, as after this error occurs you cant get rid of the error until you restart Vectorworks- 1 reply
-
- bug
- python api
-
(and 1 more)
Tagged with: