# Run a python script with command line arguments

**URL:** <https://discourse.slicer.org/t/run-a-python-script-with-command-line-arguments/36718>\
**Category:** Support\
**Tags:** python\
**Created:** [June 12, 2024, 11:25am UTC](https://discourse.slicer.org/t/run-a-python-script-with-command-line-arguments/36718 "2024-06-12T11:25:34Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![RafaelPalomar](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/rafaelpalomar/32/1436_2.png) [@RafaelPalomar](https://discourse.slicer.org/u/RafaelPalomar)\
**Post date:** [June 12, 2024, 11:31am UTC](https://discourse.slicer.org/t/run-a-python-script-with-command-line-arguments/36718/2 "2024-06-12T11:31:43Z")

</div>

@RomanStriker, check this post and see if it helps:

> [@Slicer parameters conflicts when adding "--load-file" and "--python-script"](https://discourse.slicer.org/t/slicer-parameters-conflicts-when-adding-load-file-and-python-script/33390):
>
> Slicer.exe, “–python-code”, “print(‘Start Slicer from Blender!’)”, “–python-script”, startup\_slice\_script\_file When adding both “–load-file” and “–python-script”, “–load-file” will not be executed to load .mrb file, and it only executes “–python-script”. Is there a way of adding both parameters and make it working? Thanks.

---

_[View the full topic](https://discourse.slicer.org/t/run-a-python-script-with-command-line-arguments/36718)._
