Re: [Tutor] You are right.

2015-08-04 Thread Alan Gauld

On 04/08/15 10:22, Ali Moradi wrote:

About the listbox from sqlite, yes you are right, i'm beginner in python,
and i watched many videos and study books, but i can't write what i want to
:(, i mean i know the python basics (like data structures and...), i know
tkinter basics and how to write widgets, but i don't know how to relate
widgets to my code:(, it is my biggest problem,


Don't worry about OOP yet, you don;t need it for what you
are doing and it will be just one more area of confusion.

But you should try to understand what you are writing because
if you don't you will never fix it when it breaks. And it
will break.

Most of all don;t write too much code at one time.
Limit yourself to around 10 lines at a time. Then test them
and make them work before moving on. As you get more experienced
you might write more between tests, but even now I rarely
write more than 20 lines between tests.

You are much more likely to figure out how 10 lines work than 50.

With a GUI that might just involve getting a blank window up
on screen. Then you add some widgets. Then some more. and so on.

Once you have the UI with all its bits in place and working
with dummy data you can start to write the program logic and
connect it to the UI one function at a time.

If you find a bit of code you don't understand, rather than
just paste it in as-is come back here and ask us to explain
it (providing the context from where you found it and exactly
what you don't understand)


--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos


___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor


[Tutor] You are right.

2015-08-04 Thread Ali Moradi
About the listbox from sqlite, yes you are right, i'm beginner in python,
and i watched many videos and study books, but i can't write what i want to
:(, i mean i know the python basics (like data structures and...), i know
tkinter basics and how to write widgets, but i don't know how to relate
widgets to my code:(, it is my biggest problem, and also i can't write OOP
programs with classes and definitions, which is not good.
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor