# Editing Rhino Options from Python - Run Command on Startup

**URL:** <https://discourse.mcneel.com/t/editing-rhino-options-from-python-run-command-on-startup/150400>\
**Category:** Rhino Developer\
**Tags:** windows, python\
**Created:** [November 10, 2022, 8:45am UTC](https://discourse.mcneel.com/t/editing-rhino-options-from-python-run-command-on-startup/150400 "2022-11-10T08:45:22Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Tom\_P](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/tom_p/32/766520_2.png) [@Tom\_P](https://discourse.mcneel.com/u/Tom_P)\
**Post date:** [November 10, 2022, 12:49pm UTC](https://discourse.mcneel.com/t/editing-rhino-options-from-python-run-command-on-startup/150400/4 "2022-11-10T12:49:13Z")

</div>

rhinoscript can:

[StartupScriptCount](https://developer.rhino3d.com/api/rhinoscript/application_methods/startupscriptcount.htm)  
Returns the number of startup scripts.

[StartupScriptList](https://developer.rhino3d.com/api/rhinoscript/application_methods/startupscriptlist.htm)  
Return the list of startup script files.

[AddStartupScript](https://developer.rhino3d.com/api/rhinoscript/application_methods/addstartupscript.htm)  
Adds a startup script to RhinoScript.

[DeleteStartupScript](https://developer.rhino3d.com/api/rhinoscript/application_methods/deletestartupscript.htm)  
Removes a startup script to RhinoScript.

my guess is, if you add a file with .py this will also run.

You might also workarround by calling a command of a custom (your) (rhinocommon) plug-in.

rhinoscript is directly accessing the c++ sdk methods.  
phyton and rhinoscriptsyntax are based on rhinocommon.

 ![](https://global.discourse-cdn.com/mcneel/uploads/default/original/4X/7/5/c/75c6679869bbe3dd458ae95677e079ee339f05cf.png)  
[image from here](https://developer.rhino3d.com/guides/general/rhino-technology-overview/)

there might be difference of what is accessible.

i never tried, but you might also be able to add a startup script using a macro.  
starting with  
!-\_documentproperties \_options

because of this [thread](https://discourse.mcneel.com/t/addalias-lastloadedscript-and-addstartupscript-in-python-creating-commands/47360/4) i think @stevebaer might be the right person to answer your question with more details / options / alternatives.

---

_[View the full topic](https://discourse.mcneel.com/t/editing-rhino-options-from-python-run-command-on-startup/150400)._
