Receiving no attribute error

I am trying to complete this tutorial for managing menus here on youtube.

Everything is fine until I try to reference the function in my custom container extension. 7:42 roughly in video.


project1 error.tox (20.3 KB)

Can anyone please tell me why this isn’t working like the video? I am doing the same thing and it doesn’t work.

LOL

Functions have to start in capitals apparently?

def gotoPage() doesn’t work but def GotoPage() does…

This is painful to learn from scratch and as embarrassing as it is to not know know simple stuff like this, I will leave it here in case someone else needs it. /sigh

Hi @Jesse_Walker,

yup, capitalizing functions will “promote” them to be directly accessible while lower type function names will only be accessible via the ext member. A more in depth explanation can be found here:

cheers
Markus

1 Like

Hey Markus - a little off topic but What would you suggest is the best route to learning a little Python for use in touch designer like this? I have done some coding in the distant past but have done very little in Python but can see how learning a little more might help a lot. Best book(s)? Tutorial(s)? Course(s)? Other?

Any expert advice greatly appreciated… for us non-programmer types…

Hey @gordharris,

this is difficult to answer :wink:
I would point to alltd.org as a resource atm. There is a good collection of various videos that give a good introduction to scripting in TouchDesigner. Hopefully, with python being fairly readable, it will become familiar through practice. @OwenLoweryProjects has some nice Python related videos https://alltd.org/touchdesigner_pythonscripting/ and also @raganmd has a great resource on his website here: Python in TouchDesigner – Matthew Ragan

Best
Markus

2 Likes

Thank you Markus! This should keep me going for a few months! Keep up your great work - always enjoy your sessions and teaching.

Cheers

Gord

1 Like