Open the button editor for the button you just created and take a screenshot of what it shows.
You also appear to have an extra space between the last backslash and the A in AverageArcThruPoints… I don’t know if that matters.
the screenshot before was what rhino threw up when that button was run,.
so I need to find the Cancel that error refers to in the coding or path if thats what it ses and causes that error in the command line.
Floundering
Code makes me feel sea sick. days spent fiddling, not drawn a thing. weeks of PC rebuild still to do and work overdue.
This has nothing to do with “code”, this has to do with how you set up the button.
It should be like this:
! _-RunPythonScript (
<your full path to the script in quotes>
)
You don’t have the parentheses nor the ! plus a a space at the beginning.
If you set it up like that and it still doesn’t work, report back. And do take out that extra space in the path as I mentioned above, just in case. Plus make sure the script is really in the folder where you are pointing to.
I do this and it runs. its very useful, nice tool Mitch.
However, that means I have a typo in my code.
and I dont know where, as I copied the address from properties of the .py code, then placed the .py file name on the end (and now have removed the erroneous gap)…
D:\RHINO 3D WORK AND ASSOC FILES\Plug-ins and Scripts\AverageArcThroughPoints Helvetosaur
and file is
AverageArcThruPoints3.py
I have for code:-
-_RunPythonScript "D:\RHINO 3D WORK AND ASSOC FILES\Plug-ins and Scripts\AverageArcThroughPoints Helvetosaur\AverageArcThruPoints3.py”
and pasting it here it doesn string it as one line but thats the forum window.
perhaps there is a way of pasting it ?
I will post this then look for Helvetosaurs recent method and try that.
‘’‘python-_RunPythonScript "D:\RHINO 3D WORK AND ASSOC FILES\Plug-ins and Scripts\AverageArcThroughPoints Helvetosaur\AverageArcThruPoints3.py”’‘’
um, that didnt work, three backticks name of code paste code three backticks.
I have a ’ under the @ symbol, I have nothing else. and is -_RunPyth etc etc the python code ?
To accurately copy the file path to a folder:
Browse to the folder in Windows Explorer. In the title bar you have the path in the form of Bla > Bla > Bla > Etc.
Click once in the empty space next to it, and the path will turn into the classic Bla\Bla\Bla\Etc.
and the whole path be highlighted. Ctrl+C and then paste it where you need.