# Cannot import tkinter in excel

**URL:** <https://forum.anaconda.com/t/cannot-import-tkinter-in-excel/74517>\
**Category:** Python in Excel\
**Created:** [June 6, 2024, 5:07pm UTC](https://forum.anaconda.com/t/cannot-import-tkinter-in-excel/74517 "2024-06-06T17:07:53Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![derek7594](https://avatars.discourse-cdn.com/v4/letter/d/0075a9/32.png) [@derek7594](https://forum.anaconda.com/u/derek7594)\
**Post date:** [June 6, 2024, 5:07pm UTC](https://forum.anaconda.com/t/cannot-import-tkinter-in-excel/74517/1 "2024-06-06T17:07:53Z")

</div>

When I type python code “import tkinter as gui”, I got an error message “ImportError: libX11.so.6: cannot open shared object file: No such file or directory”

How can I setup the environment to use tkinter in excel ?

![tkinter_cannot_import_in_excel](https://europe1.discourse-cdn.com/anaconda/original/2X/9/9feafab406a05f50786c879a4a37619b6e484361.jpeg)

---

<div class="post-metadata">

**Author:** ![Jim\_Kitchen](https://avatars.discourse-cdn.com/v4/letter/j/f5a800/32.png) [@Jim\_Kitchen](https://forum.anaconda.com/u/Jim_Kitchen)\
**Post date:** [June 13, 2024, 3:47am UTC](https://forum.anaconda.com/t/cannot-import-tkinter-in-excel/74517/2 "2024-06-13T03:47:36Z")

</div>

Python in Excel does not have support for graphical displays such as tkinter. It is intended to return objects which can be displayed within the Excel grid (scalar, list, DataFrame, etc).

While there is support for matplotlib images, those are returned as static images (png) rather than interacting with the window system directly.
