C# Geometry Output Diagnostic: Minimal Sphere Test
I am attempting to diagnose an issue where certain C# components execute successfully in Grasshopper but fail to output any geometry to the Rhino viewport. I have created a minimal test case and would appreciate it if others experiencing similar problems could replicate this to confirm if this issue is system-specific or widespread.
The Setup
Please place two components on a fresh Grasshopper canvas:
Number Slider: Name it R and set its value to 10.000.
C# Script Component:
Set the input name to R (double-click the input grip).
Set the output name to Output (double-click the output grip).
Connect the R slider output to the R C# input.
The Code to Paste
Double-click the C# component, delete the existing code, and paste only the following lines inside the RunScript function. This code attempts to generate a single sphere with radius R and output it as a BRep.
C#
void RunScript(double R, ref object Output)
{
// Simple Test: Generate a sphere and output it.
Output = new Rhino.Geometry.Sphere(Rhino.Geometry.Plane.WorldXY, R).ToBrep();
}
The Failure Result (The Key Observation)
After closing the C# Script Editor, the component should re-run.
Observation: The C# component executes and turns Grey.
Critical Failure Check: Go to the Rhino viewport and execute the Zoom Extents command.
If you are experiencing the issue I am seeing, the result will be:
Component Status: The C# component is Grey (no syntax errors).
Rhino Viewport: NO Sphere geometry appears.
If you observe this behavior, please reply to this thread. This failure confirms a fundamental blockage preventing C# components from sending geometry to the Rhino display, even when the code compiles successfully.

