C# script not showing in rhino8

Hi everyone,

so I’m very new to programming in C# and although some of the short scripts I’ve tried so far work, I’m having trouble with some very basic stuff that I can’t figure out. I’m trying to construct a somewhat complex polyline whose vectors or points are not in one plane. The script seems to work (no reports in the output panel, plus the patch is grey and not red or orange), but I only see the points in Rhino and not the polyline connecting them.
Has anyone had this problem and has any idea why this is happening?

Thx in advance

Can you include the GH file in the post, we can take a look.

sure, here it is
240424_polylines_c#.gh (17.5 KB)

There are a few issues here.

We have made changes to the way the Script component, which works in later versions of 8 to output a polyline as a special case. What specific Rhino version is being used here?

Also, I do not all the input geometry of the example file. Can I also get the 3DM this goes with? Or the input Geometry can also be internalized. Technically, as a workaround for earlier version, by following the Script output with a Curve component will draw the curve.

Here is a quick test I created:


In RhinoCommon a Polyline is really an ordered set of points. A PolylineCurve is a set of line segments connecting points. In Grasshopper we decided special case the Polyline to act like a PolylineCurve when moving thru components.

works if you do this

I think that either what you had in the geo components wasn’t working with the script, was too far away from the viewpoint, or maybe the geo component doesn’t work well with vectors

Vectors are not really Geo objects in Rhino.

1 Like

Hi everyone,
thank you for your replies.
After trying some of the suggested solucions and not having any luck with them, i noticed that there is a type hint at the output geom - which wasn’t there in previous versions. By choosing polyline it worked just fine.
Sorry for my late reply