How to execute an external py-file with a button

Hi @joeycarr

Thanks for the short tutorial.
Strang a bit that it is so difficult: I want to have a button, and when some-one presses on it, it does what I already made. (Is button pressed: do that, finish). But it is the way it is.
I will dive a bit more into python which I really need to do to finish my addon:

There you see the script that generates a colour palette and settings for a shader. I can run the script and it works. I will find out with help from your info how I can make it more userfriendly (making an addon of it).

Regards, Peetie