Hello Dave,
Thank you, for your help, I'll try my best.
To all others, PLEASE be pleasant with my nescience, I'll tried to describe not a specific error at my Program. I'll tried to get rid of that missing link this sample is only theoretic, but the code really exists and is over 1000 lines long.
I understood how to transmit data to a class,
This is an example where terminology is messing up communication. To me,
transmission implies communication between two different active systems,
like across a network, or at least between processes. A class isn't
active at all, it's a holding place for attributes (class-attributes),
and it's indirectly a description of what instances will look like.
Most likely what you mean is you know how to pass data to an instance
method of a class. Or how to set class-attributes, or
instance-attributes, which are not the same thing.
but I do not understood how that class could access an SQL object, that is allready opened at a other class without getting into troubles with sqlite.
I don't know sqlite, so I don't know what might constitute 'getting into
troubles.' But a class method (not the class itself) is given a self
object, and other parameters, and if one of those parameters is an SQL
object, it can be manipulated there just as readily as wherever that SQL
object was first discovered.
For my understood, the newsgroup isn't a place only to solve concrete problems. I think you're not only a "helpdesk"
, If I'm at the wrong group to get some Ideas how to solve my "issues"
We're a disjoint bunch of volunteer teachers, and a bunch of learners,
and each of us spends some of our time in each role. Most people spend
quite a while "learning," or at least lurking, before asking questions.
Then a bunch more before being ready to answer questions and make useful
comments. But it's not a linear process, and nobody takes a test to
qualify for "teaching." The goal of this forum is to field the
questions which are above the level of python-tutor.
More importantly than the "purpose" of the forum is that the nature of a
forum is that you have to get the interest of enough readers that
somebody knowledgeable about your problem will actually jump in and help
solve it. There are a number of ways to discourage useful responses,
and one of them is to write confusing comments or non-working code. Of
course, confusing phrasing can be a language issue, or it can be an
understanding issue. But it's easy to tell when there's non-working
code. If it doesn't run, it's not working. Is that a problem? Depends
on the nature of the question.
Ps.: DaveA I don't know how to say it, but I treasure your great work here, giving such detailed good answers.
To the others, he's referring in part to an offline apology, where I
offered some detailed suggestions.
PPs.: I know, that my codingstyle isn't that great, I've haven't programmed the last two years. You're welcome to guess what I've worked 8 years long.
you will laugh till you fall of your keyboard
PPPs.: I' will use that day to check out the PEP's and correct my coding style, and naming.
http://www.python.org/dev/peps/pep-0008/
describes coding guidelines. But please note that the places where
I was correcting your capitalization, it was only a small part of pep8,
the parts which are most likely to be causing confusion between you and
us. It's important to get your mind around the differences between
modules, classes, instances, attributes, etc., and when we use the
appropriate capitalization, it tends to show we're understanding it.
There are other things in pep8 that haven't been mentioned here, and
there are many things I don't follow. But for example I use 4 spaces
for indenting, and never tabs. Some people prefer tabs, and python
permits it. But mixing them is real hazardous, since code may seem to
be doing one thing and actually do another if the way you expand the
tabs is different than the way the compiler does. But the real problem
online is that your tabs may work great with your toolset, but once you
put it in a message, they may work entirely differently to the hundreds
of different toolsets we use to view and/or try out your code.
Pep8 recommends a particular style within a function name, separating
'words of a name by underscore. I happen to loathe that style, so I'm
clearly not the one who would critique someone for not following the
guideline. I say getFile(), the pep says get_file().
Anyway, Pep8 is a guideline.
I think you need a tutorial, badly. Two years of not programming is no
big deal, but you don't seem to understand a number of very fundamental
concepts, or at least not understand them well enough to express them.
The real question is probably what other language did you use, and were
you a master at it, or just dabble. No offense intended, you've never
said whether this is your primary career, nor how old you are, nor any
other thing which might let us guess.
I like software, (though I took 8 years off to run a photography
business (and moonlighted about 3 years of the time to supplement the
income). But I insist on creating a useful mental model of how a
language and/or system operates. Then I modify that model when things
prove to be wrong. So a tutorial that might be good for me might not be
the right one for you. The two that I'd suggest are:
http://docs.python.org/tutorial/index.html - the official one
http://www.alan-g.me.uk/ - Alan Gauld's tutorial. I don't know it, I
just see how much help Alan is here and elsewhere, and Assume the
tutorial is similar
I'm going to continue in another message later, trying to do a "jump in
the middle and answer some questions which may have been asked, or
should have, or something."