Added: 2 years ago
From: thenewboston
Views: 65,947
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:
see all

All Comments (168)

Sign In or Sign Up now to post a comment!
  • Tanks a lot bucky this tutorial is very clear and useful

  • I was looking for a good Language/GUI combo for bioinformatics and Java was so difficult (from a biologist perspective). Glad to see wxPython works on Mac.

  • @ fyrestarz how did you get wxpython to work on python 2.7 ? What link did you download from wxpython.org?

  • Can you update it? I'm using Python 3.2.2

  • @speedyguy8 why are you watching this video if your not a noob yourself? And he knows many many languages, he is not a noob haha. You sir, are an idiot =]

  • @MrNeemer

    PLEASE DO NOT FEED THE TROLLS

  • @MrNeemer I do think he could have done a better job of explaining what's happening more than just "that's just the way it is". It's entirely possible to create a frame without classes in just as many lines, it's not required, but it makes it easier. It's called a frame because it doesn't always have to be a window. A frame is simply anything that can contain a window that isn't another frame or dialogue. In WX you aren't manipulating windows because, some systems have different functions.

  • Thanks a lot man!!

    I have followed your complete Python tutorial and now I am continuing with this one. It is extremelly clear and helpfull. Keep the great work!

    (This is the blood, and this is the face, I love it)

  • can someone explain why the initialization thing takes in three parameters nd wht exactly is parent and id??

  • python 2.7 does not support wx, i tried but shows error

  • @fuckslipknot21 it workd for me

  • Man these are so much more helpful than the stuff that is online.

  • doesnt work with latest version

  • Mine says invalid syntax on = def__init__(wx.Frame): <---------Says thats a invalid syntax :( ":"

  • great tutorials and all--amazing. Well done... Just a piece of advice: don't take the first minute explaining what you did in the last video; it's kind of annoying.

  • when i try to run it, its comes up with a syntax error and says "unindent does not match any outer indentation level" what do i need to do to make it work

  • @speedyguy8

    He's not a noob, he's teaching many different languages at once... it can get confusing...

  • @speedyguy8 you dumb ass dont call him a noob hes really smart he knows just about and probably every programming lanuage

  • everything works but my title (frame aka window) is not there.

  • Can't wait until they come out with wx toolkit for python3.0

  • @Aulakh750 any idea of when that might be?

  • @tyebillion no clue but there are lots of other GUI toolkits available for python 3.0

  • wxPython canot download b/c it says it cannot execute my python command line? so i have been trying to reinstall it which one should i choose:

    Gzipped source tar ball (2.7.2) (sig)

    Bzipped source tar ball (2.7.2) (sig)

    XZ source tar ball (2.7.2) (sig)

  • if it says 'no module named wx' you probably installed the wrong bit #. I downloaded the 64 bit and that error popped, then downloaded 32 and wrote over 64 and it works. :D

  • Comment removed

  • thanks buddy ,your tutorials are amazing keep it up.

  • ok how do you close the First window we made.

  • ok, can someone help?

    when i try ro use the frame code that bucky shows, i get an error:

    AttributeError: 'module' object has no attribute 'frame'

    WTF??? can anybody help??

  • @marttiliveshere One reason should be because you must of downloaded a different wxPython version than your Python has. Ex Problem: wxPython2.6 / Python2.7, make sure your wx is the same version.

  • @KennyDupp I have the same problem but I have redone it multiple times and made sure it is the right one

  • @marttiliveshere it's case sensitive

  • You should make yabasic tutorials.

  • Ah, so this is the 45th tutorial

  • does this work for python 3.2 or 2.7? or does it only work for 2.6?

  • @FangMaxIggy It works with 2.7 for me ;) idk about 3.2 though

  • @FangMaxIggy I had to uninstall 3.2 and install 2.7, it worked.

  • @FangMaxIggy All python includes have the python version number at the end i.e wxPython2.6 is for python 2.6 and etc..

  • what is the id for?

  • You should always capitalize a class!

  • For everyone that gets the 'no module wx' message, I solved it by uninstalling wx and reinstalling it without having Python open.Hope that helps!

  • when i run wx python it shows an error says no module named wx plssssssssssssssss help me

  • How can you embed your own icon to app using wxpython? or can you do it using py2exe after you're done with your wxpython code?

    Thanks.

  • everyone having problems use this

    from wxPython.wx import *

    class MyApp(wxApp): def OnInit(self): frame = wxFrame(NULL, -1, "Hello from wxPython") frame.Show(true)

     self.SetTopWindow(frame) return true

    app = MyApp(0)

    app.MainLoop()

  • hey,, hmm ,, im wondering where do i need to set to get the pop up methods or instances when type "." or "="

  • It shows me an error

  • Can you Show how it works on Mac?

  • <3 PyQt4

  • alright, i followed this to the T and some how i got an error?

    if __name__ == '__main__' :

    right at that semicolon is where i get it at. i'm not to sure if its because i'm running the 2.7 version of python or not, but havn't seen anyone else with this issue. if someone could help thats be great.

    (sorry for mispellings)

  • everyone can ignore this. turns out i forgot caps.

    so everyone remember, put your caps where bucks got them. it'll help you out in the long run.

    haha

  • Comment removed

  • @9mankaido3 No, it's not an issue with Python 2.7. try typing __name__ in the python shell and if it returns '__main__' the error is somewhere else. Or you could get rid of the conditional statement and go directly to app=wx.PySimpleApp()

  • @9mankaido3 well thats my error too

  • @9mankaido3 i get this exact same problem. its been a while since you posted this, so im wondering if you figured out a solution?

  • @DanielYeller

    sorry for taking a while, just been a bit busy and kept forgetting to reply. but you gotta make sure you got all of the caps in the same spot the buck has them in. took me roughly twenty mins to figure it all out.

  • mine wont show up.. the test from the installation tutorial worked... but this doesnt. What should i do?

  • Hi bucky

    I am getting SyntaxError: invalid syntax in (def__init__(self,parent,id):)

    can u please assist

  • @motivaraskamlesh0405 you need a space after def, I believe. And I do not think you need the first and last parentheses

  • i get error with one of my : des__init__(self,parent,id)>:<­thats where it is help

  • ohhhhhhhhhh very very very helpful!!!!!!!!!

  • ok , i fixed the problem , to those who face the same problem as mine . try reading the previous comment , it help a lot

  • erm , guys , im having a trouble , it said ImportError: No module named wx . any suggestion ?? please

  • @wakao56 this means you haven't downloaded the wx libraries, or if you installed them it's corrupted. Check the video description video if you don't know what I'm talking about...

  • oh so you change the name to wxpython tutorial okay so your not that guy speaking spanish or something cool

  • I already watched every tut now i am going to watch again and put them together to make one program.

  • Comment removed

  • bucky i am able to convert .py to .exe using py2exe for a normal python program but it doesnt work for wxpython !! :( it ll be great if u could help me on that

  • gives me an 'ImportError' 

  • Comment removed

  • Comment removed

  • @EricisSpade re install wx

  • @EricisSpade did you install the right wxPython???

  • @EricisSpade a little late or you but for new people here. Make sure to close Phyton before instaling

  • @EricisSpade You need to download the proper version of wxPython for your version of Python.

  • @EricisSpade uninstall it and reinstall without IDLE(GUI) open or running

  • @EricisSpade you didn't install correctly

  • @EricisSpade if you get wx is not a module that means you either have not installed it or did not install correctly

  • @EricisSpade Make sure you have the same bit files, and the same version(2.7)

  • more python please.

  • very understandable ,thankssssssssssss

  • Adding the space after "def" fixed the syntax error for the :

  • @LVCMS dude thanks i couldnt figure out the error

  • @LVCMS Thanks alot lol i checked five times and din't notice that!

  • when i did this it said syntax error what does that mean 

  • Goodie! More bucky tuts! Thought was gonna run outta stuff to watch :DDD

  • Can someone inform me on what does the " Self,parent,id" parameters mean ?

  • just noticed my error was spelling import with an n

  • im getting a error message........this is wat i have is it correct?

    import wx

    class Goon(wx.Frame) : def __init__(self,parent,id) : wx.Frame.__init__(self,parent,­id,'frame aka Goon', size=(300,200))

    if __name__=='__main__': app=wx.PySimpleApp() frame=Goon(parent=None,id=-1) frame.show() app.MainLoop()

  • @MisterGoon1 i had an error...i deleted my python26 directory and installed python 2.7 with wxpython---it works fine now!

  • You just helped 27766 people to become programmers

    thank you Bucky, THANKS ALOT! :D

  • there is wx for python 3?

    would you please give a tutorial about python 3

  • Im getting the error on the colon following the if statement.

    Anybody know why?

    Thanks

    if __name__=='__main__':

  • @alexmillar you are missing a space after "if"

  • @alexmillar languages are picky and your error could just simply be that you didn't put a space after your if statement to separate it from __name__

    That error happened to me. If it's highlighting the colon its probably something in the same line before it. 

  • How would i change the color of the background? and how would i attach the program I made in python to the frame and button i made for it please help thanks in advance could anyone help please?

  • Gee, so much code and so complicated just to get a very simple gui.

    Guess I am spoilt using AutoHotkey as getting a simple gui is erm Simple!

  • @sueroski Bucky may have to start doing English tutorials.

  • For those of you using IDLE in Linux wondering why it will only run once, and then throw an exception the second time: The problem is in the last 5 lines of code. I'm pretty sure that 'app' never gets deleted after the first time you run it, therefore it doesn't create a new one each subsequent time you run it, and it collides with itself.

    My fix:

    1)Change 'app' to 'app1' or whatever variable you choose (just not app)

    i.e. app1=wx.PySimpleApp()

    2)Add line:

    del app1

    to the very end of the code.

  • how to add keyboard event to wxwindow

  • Whenever i run this program the frame pops up but after about 5 seconds it fades to gray. I can still see the frame and the letters but i just changes color. Whenever i close the frame it closes python as well. Any help??

  • thanks u

    

  • When I try to import wx it comes up with an error that says there's something wrong in __initi__.py line 45 and _core.py line 4 or something

    Any suggestions?

  • does it have to be wx ?????????

  • I am really enjoying your tutorial series',especially Python and Blender, but I was wondering: where did you learn how to use python? did you learn a different lang first?

  • This is too shallow of an explanation. You didn't say what are the Parent and the Id parameters are for. I don't like to just copy what you do here. I'd like to actually understand it.

  • @elad135 He said he would explain it later on :)

  • Leave it to thenewboston to put up easy to understand tuts about programming. Your videos provide a great companion learning guide to the (sometimes) more rigorous textbooks. I like watching your videos when I need some clarity on something related to Java programming or wxPython. I hope you put up some tuts for Python, even if it's a pretty simple language to learn- might find something in your videos that I didn't find in the books. Thanks for all your uploads, very helpful.

  • how do you get that drop down list after app=... at 4:34?

    it does not apper for me.. :(

    /w

  • BOOM? wtf happened to BAM? :[

  • try restarting computer after downloading wxpython

  • thanks great stuff

  • now i need to remake my whole calculator D:

  • help me anyone i keep getting stuff like this Traceback (most recent call last): File "C:/Users/Kavun Nuggihalli/Desktop/kavun.py", line 1, in <module> import wx

    ImportError: No module named wx

    i cant do any wx python i have watched every vid and i cant get wx python

  • @badcurryboy why is wx installed on your desktop

  • well, application works but i don't understand how... if somebody has a link to a site explaining with a normal languge all this functions, please throw a link here...

  • I sorted my error guys, If your getting a error on the colon after '__main__' It was due to me not including the second closing parenthesis after stating the window size

  • ok got it work, needed to put a capital S in show

  • @briishspy lol yeh i did that one it wouldnt work til i capitalized the f in Frame

  • @briishspy what is the special s

  • can't get this f*cking thing to work! i've coppied it exactly!!

    i'm about to smash my computer through the wal

  • This guy sounds like a young Buffalo Bill - "Uh, are you about a size 14?"

  • nice videos!

  • you need to put these in a playlist

  • i really didnt understand anything in this tut

  • I am getting some issues at my side, i use the same program shown in this video....but after executing it, name is not coming in my window and there is no effect of size parameter either. :(

  • time to get onto the real stuff, finished python and now time to wxpython :P

    upcoming pygame :D

  • I was wondering where your GUI Python tutorials were. Can you put a link in the Python Programming Tutorial - 44 to this string of tutorials, please?

  • you should do tutorial for GUI stuff using Boa Constructor!! bucky you rock bro

  • Can you make the wxpython into Playlists?

    I kinda confused in searching. LOL

  • Bucky,

    How can I change the color(s) of my GUI frames and buttons.

    Thanks for the awesome tuts!

  • 4:42

    I don't have that box :S I clicked ctrl+space and even typed wx. and waited a bit and never popped up?! If you know whats wrong please reply! Thanks!

  • You need to press TAB

  • I did all of the python tutorials Bucky posted -- now onto these wxpython tut's ... wooohoo!!

  • yea, me too :D

  • @hall0ween138 Yep, me too. These are the best

  • @hall0ween138 same here!

    

  • @hall0ween138 Me too

  • :) need hlp:)...

    it says in

    "class bucky(wx.Frame):"

    'module' object has no attribute 'Frame'

  • make sure you type "frame.Show" instead of "frame.show"

  • did you import wx? because when an object 'has no attribute x' then that means x is not a method or variable of that object, which either means you forgot to add it, the object dose not exist, or there is a spelling error

  • ty sooooo much for the tutorials, LOVE them, they have helped alot, keep up the good work :)

  • RED4MIX learn to listen dude... he saied that the tutorial on how to install wx is on the video description========> just listen first then talk later. Great Video! Great Tutorials!

  • want you please shut it up dude

    i followed and listened to all the 44 python tutorials in 1 night, specially tutorial 44, and that didn't help me so much to install wxpython. now i solved my probleme cause it have nothing to do with what presented in that tutorial.

  • thanks from Spain, u are a great teacher thanks a lot.

  • can't install wxPython

    you did a great job, but you didn't explain the most important and basic thing, how to install wxpython

    thaks

    >>>import wx

    ImportError: No module named wx

  • Can someone please help me. I keep getting a syntax error!

    At this line of code:

    def_init_(self,parent,id):

    it says it is the colon causing the problem.

    When i remove the colon it says unexpected indet.

    Please Help Me!

    Anyone!

  • @Blakerules1206

    have you tried adding a space after 'def'?

    like def __init__(self,parent,id):

    :D

  • Comment removed

  • what does the self means

  • i have a very big problem.

    I watched the tutorial and everything, and i came up with an error.

    The error says that could not find the wx module.

    I dont know what to do.

    Please help.

  • Must install wxpython

  • Just commenting, you really dont need to use wxPySimpleApp, the App and that are really not so different any more and it is basically easier.

    app = wx.App(redirect = False)

    the redirect just makes errors still go to IDLE.

    So yeah, just saying that perhaps the pysimple app is not necessarily the way to go. Good job though :)

  • Very nice Greg, its nice to see tutorials with lots better resolution then mine :P

  • Comment removed

  • Description.

  • coolio

  • very helpful Tutorial

Loading...
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more