Quantcast
Channel: Scripting - McNeel Forum
Browsing all 5938 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

Grasshopper Script Editor - Error occured in command "Options"

The options do not open in any of the editors (pyhton, C# etc..) see the error message below. Version 8 (8.19.25132.01002, 2025-05-12) 1 post - 1 participant Read full topic

View Article


X-axis auto rotate script

I have a script, attached, which I want to use for orienting curves or polysurfaces so that the longest edge of their bounding box is aligned to the X axis. It sort of works but I can’t a truly tight...

View Article


How to rotate viewport to absolute angle?

Using the method Rhino.Display.RhinoViewport.Rotate, I can rotate the viewport in increments: 2025-06-07+02_rotate.py (201 Bytes) Now I wonder how to set the rotation to an angle relative to the...

View Article

Image may be NSFW.
Clik here to view.

Is this possible to select only the intersected objects?

3 posts - 2 participants Read full topic

View Article

Object made out of tetrahedrons

Here’s a video demonstrating how my script works:tetrahedron python command The tetrahedron that is being created is a pre-set block called “tetra” Here’s the script itself: # -*- coding: utf-8 -*-...

View Article


Image may be NSFW.
Clik here to view.

Rhino WIP: Matplotlib plots

In Rhino 8, plotting from matplotlib causes a confusing flurry of windows to open over Rhino or would cause a crash. Neither case made it easy to work with this library. Next build of Rhino WIP...

View Article

Image may be NSFW.
Clik here to view.

Issue with CreateFilletCornersCurve not returning None on error

Hi, just trying to use the following command: “Rhino.Geometry.Curve.CreateFilletCornersCurve” The issue I’ve run into is when a curve is passed into it that can’t be filleted (i.e. a rectangle that...

View Article

Image may be NSFW.
Clik here to view.

Rhino WIP: Unit/Regression Testing

More often than not we work on complex workflows when scripting in Rhino. While working on a code that is trying to wrap a complicated workflow, it is possible for changes to break previously coded...

View Article


Unable to create a block in Rhino " No Template" mode

Hi team, I am unable to create a block when I am in “no template” option. is it a rhino limitation or am I missing something . int idef_index = Rhinodoc.InstanceDefinitions.Add(idef_name,...

View Article


Attaching Python Script to Icon (ASCII & Syntax Issues)

Hi everyone, I have a Python script that runs perfectly in the Script Editor (Tools > Script > Run). However, when I try to attach it to an icon, I get two errors: First, it complains about a...

View Article

Two Rhino Python scripts from a single alias?

Hi, Can I run two Rhino Python scripts from a single alias, and make sure the second one starts after the first one finishes? I’m trying to solve a timing issue where the first script must complete...

View Article

Image may be NSFW.
Clik here to view.

SaveAs dxf alters geometry

Hello everyone, This code to save a dxf file… filt = "{} Files (*.{})|*.{}||".format(ft,ft.lower(),ft.lower()) if not filename: if filename==None: return e_file_name = '"{}" '.format(filename)...

View Article

Image may be NSFW.
Clik here to view.

UnrollSrf component suddenly dysfunctional

I have a big script (>10MB), made for a client. Somewhere i flatten 3D BReps to 2D outlines for fabrication purposes. I do this using a Py3 component with just a simple UnrollSrf command. It worked...

View Article


IsObjectValid(object_id) returning error

Hi everyone, I’m getting an unusual behaviour when using IsObjectValid(object_id) to check a particular geometry. Sometimes, it returns the message: “00000000-0000-0000-0000-000000000000 does not...

View Article

Assigning named sub-object materials in script

I’m working on a UI for assigning materials to surfaces. I specifically want to assign to polysurface faces. The UI has an alpha list of materials in the file and an “assign” button which prompts for...

View Article


GetString only displays 3 string options?

Does GetString have a limit to the amount of strings shown in the command line? I’m trying to test using it with 5 options but it doesn’t display them all and also only ever shows “Connector”,...

View Article

Image may be NSFW.
Clik here to view.

Rhino WIP: On Python Environments

TLDR In the next build of Rhino WIP, Python environments are now set up using python -m venv module and therefore have their own python and pip binaries. This change should NOT affect how your scripts...

View Article


Rhino Script Editor - GHA. File Compiler

Hi all, Has anyone else experienced issues with the ScriptEditor in Rhino 8? I’ve been using it to compile various GH Python components into a .gha plugin. However, once I place the compiled .gha file...

View Article

Image may be NSFW.
Clik here to view.

Remove Conduit Display When Py Component is Disabled or File Switch/Close

I had a Python script to control display.conduit in Rhino, using an input toggle to switch the display on or off in the viewport. This works as expected when the component is enabled. However, when I...

View Article

Image may be NSFW.
Clik here to view.

Python package not loaded correctly anymore

Hi @eirannejad, update 18/06 - 11:59 Issue is resolved. It turned out i did not use `ifcopenshell.api.owner` before, other than I thought. I now use `ifcopenshell.api.run('owner.create_owner_history',...

View Article
Browsing all 5938 articles
Browse latest View live