# 'NoneType' object has no attribute 'print

**URL:** <https://forum.inductiveautomation.com/t/nonetype-object-has-no-attribute-print/44863>\
**Category:** Ignition\
**Created:** [March 24, 2021, 4:02pm UTC](https://forum.inductiveautomation.com/t/nonetype-object-has-no-attribute-print/44863 "2021-03-24T16:02:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![diego.bianchi](https://avatars.discourse-cdn.com/v4/letter/d/958977/32.png) [@diego.bianchi](https://forum.inductiveautomation.com/u/diego.bianchi)\
**Post date:** [March 24, 2021, 4:02pm UTC](https://forum.inductiveautomation.com/t/nonetype-object-has-no-attribute-print/44863/1 "2021-03-24T16:02:45Z")

</div>

Hello,  
i create a button with this script:  
table = event.source.parent.getComponent(‘Table’).print()  
but when try this button compare this message:  
.  
Traceback (most recent call last):  
File “event:actionPerformed”, line 1, in   
AttributeError: ‘NoneType’ object has no attribute ‘print’

Ignition v8.1.3 (b2021030309)  
Where is the problem?  
For other button create same function for file .csv, this is the script:  
table = event.source.parent.getComponent(‘Table’).exportCSV(“data.csv”, 1)  
and have same problem:

Traceback (most recent call last):  
File “event:actionPerformed”, line 1, in   
AttributeError: ‘NoneType’ object has no attribute ‘exportCSV’

Ignition v8.1.3 (b2021030309)

Thank you for help

---

<div class="post-metadata">

**Author:** ![bkarabinchak.psi](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/bkarabinchak.psi/32/83567_2.png) [@bkarabinchak.psi](https://forum.inductiveautomation.com/u/bkarabinchak.psi)\
**Post date:** [March 24, 2021, 4:14pm UTC](https://forum.inductiveautomation.com/t/nonetype-object-has-no-attribute-print/44863/2 "2021-03-24T16:14:18Z")

</div>

It sounds like you don’t have a component named `'Table'` anywhere in your window. Either that, or the `.parent` chain going back to it is incorrect. Use the property selector to select the table component to ensure you get the right path.

---

<div class="post-metadata">

**Author:** ![diego.bianchi](https://avatars.discourse-cdn.com/v4/letter/d/958977/32.png) [@diego.bianchi](https://forum.inductiveautomation.com/u/diego.bianchi)\
**Post date:** [March 25, 2021, 8:27am UTC](https://forum.inductiveautomation.com/t/nonetype-object-has-no-attribute-print/44863/3 "2021-03-25T08:27:58Z")

</div>

Where is the property selector?
