# Rhino - Python script output

**URL:** <https://discourse.mcneel.com/t/rhino-python-script-output/137546>\
**Category:** Rhino\
**Tags:** windows\
**Created:** [February 7, 2022, 8:33am UTC](https://discourse.mcneel.com/t/rhino-python-script-output/137546 "2022-02-07T08:33:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![user774](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/user774/32/338512_2.png) [@user774](https://discourse.mcneel.com/u/user774)\
**Post date:** [February 7, 2022, 8:33am UTC](https://discourse.mcneel.com/t/rhino-python-script-output/137546/1 "2022-02-07T08:33:26Z")

</div>

Dear Sirs,

Can someone give me any advise how to obtain python script results in output other than internal Python script editor. For example I want to get tabulated data of object volume and it’s center of gravity in table in MS Word or something similar to output from massproperties command in Rhino.  
Any link to reference guidance or any book will be appreciated.  
I have tried to intsall python-docx, and it perfectly works on VSCode, transferring data to MSWord, but unfortunately import docx command did not work in internal Python script editor.

---

<div class="post-metadata">

**Author:** ![Helvetosaur](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/helvetosaur/32/635974_2.png) [@Helvetosaur](https://discourse.mcneel.com/u/Helvetosaur)\
**Post date:** [February 7, 2022, 9:11am UTC](https://discourse.mcneel.com/t/rhino-python-script-output/137546/2 "2022-02-07T09:11:34Z")

</div>

You can write text or csv files directly out of Python with `file.Open()`, `file.write()` etc… Check the Python docs for how to use this stuff.

Some samples:

> **[How to read and write a simple file](https://developer.rhino3d.com/guides/rhinopython/python-reading-writing/)**
>
> Use Python to read and write files.

---

<div class="post-metadata">

**Author:** ![user774](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/user774/32/338512_2.png) [@user774](https://discourse.mcneel.com/u/user774)\
**Post date:** [February 7, 2022, 10:31am UTC](https://discourse.mcneel.com/t/rhino-python-script-output/137546/3 "2022-02-07T10:31:24Z")

</div>

Thank you very much! I will read it.
