Try print(assetManager) to find out where the file actually resides on
disk, and make sure it’s the file you expect.
​

On 21 February 2018 at 15:10, Jason Huang <jasonhuang1...@gmail.com> wrote:

> Hi all,
>
> I got stuck at the beginning of creating a UI interface and couldn't
> figure out what was missing.
>
> ENV: Maya 2018 update 2, Windows 10.
>
> script name: assetManager.py (saved in Maya 2018 scripts folder)
> from Qt import QtWidgets, QtCore, QtGui
> import pymel.core as pm
>
> class ObjectManager(QtWidgets.QDialog):
>     def __init__(self):
>
>         super(ObjectManager, self).__init__()
>
> def showUI():
>     ui = ObjectManager()
>     ui.show()
>     return ui
>
> In Maya script editor: (python panel)
> import assetManager
> reload(assetManager)
>
> ui = assetManager.showUI()
>
> Maya errors out:
> # Error: AttributeError: file <maya console> line 1: 'module' object has
> no attribute 'showUI' #
>
> I am following a course and the same code demo-ed in the course video
> works fine in teacher's Maya session.
>
> Thanks,
> Jason
>
> --
> You received this message because you are subscribed to the Google Groups
> "Python Programming for Autodesk Maya" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to python_inside_maya+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/python_inside_maya/c31b5c6f-15d1-4203-ae10-
> 6eb59dfa2362%40googlegroups.com
> <https://groups.google.com/d/msgid/python_inside_maya/c31b5c6f-15d1-4203-ae10-6eb59dfa2362%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/CAFRtmODfGzuZs25T8%3DTiJg6CWTMfnA-X0-BTh0nOmUvxNHujYg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to