Hi,
if you change all occurences of
inputTxtOne
in the code to
self.inputTxtOne
the second variant should work:
mins=self.inputTxtOne.GetValue()
also note the typo in case:
wx.TExtCtrl >> wx.TextCtrl
hth,
vbr
--
Steven Sproat, BSc
http://www.whyteboard.org/
Basically, there are different scopes of the names (variables) used,
assigning mins = ... only makes it accessible under that name in the
current scope - in this case - the respective function (the same for
inputTxtOne). If the names belong to different scopes, they don't
"see" each other.
Using self.min ... within the class methods makes these names belong
to the class and makes them accessible across multiple methods of that
class instance (as self is passed as the first parameter of the
methods).
see e.g. http://docs.python.org/tutorial/classes.html
vbr
Both of these lines will work in wxPython. The problem you had is a
Python issue, which is that you were assigning what mins was in one
scope, but expecting to be able to print what mins was in a
*different* scope--but information like that stays in its scope (or
"namespace") only. In this case, "scope" means in different
functions. That's it. By prepending "self." to mins when you assign
it, you are telling it to be a available to the whole class, since
"self" refers to to that instance of the class. (This dot notation is
used to show hierarchy of objects, with each dot showing separating a
parent from child)
In a nutshell: if you want names to stay put within their functions,
don't put "self." in front of them (this should be the default). But
if you want to share the name among different functions, you can
either pass the name in a function call, like:
self.NameScrambler(start_name)
or you can make the name globally available by putting "self." in
front of it, like:
self.start_name
Che
I read this list by getting emails and Ray, I've noticed that some but
not all of your responses arrive to my inbox as a separate thread
instead of in the original thread. Wasn't there a discussion about
this issue some time back? In any case, would you be interested
altering what you are doing so as to not do that? I think it is a lot
better for the quality of the archive and the day to day reading of
the list for threads to remain intact.
Thanks,
Che
I would suggest that if you would like to participate in discussions
that you change your subscription settings to read messages as Email
(this is a mailing list after all) so you can properly Reply to them
from your inbox. Goto
(http://groups.google.com/group/wxpython-users/subscribe) and check
the "Email" radio button.
The problem isn't that google is messing up it just that you are
sending a new email with the same title instead of replying to the
original message. So as far as the world is concerned you have sent a
brand new email that is not part of the original message thread since
the heading data in your email doesn't contain the reply header from
the previous message(s).
Cody
On Fri, Oct 8, 2010 at 11:23 AM, Ray Pasco <pasco...@gmail.com> wrote:
>> The problem isn't that google is messing up it just that you are
>> sending a new email with the same title instead of replying to the
>> original message. So as far as the world is concerned you have sent a
>> brand new email that is not part of the original message thread since
>> the heading data in your email doesn't contain the reply header from
>> the previous message(s).
>>
>> Cody
>
> Yes, Google Groups/Gmail is messing up.
>
> I have always had the "Digest Email" radio button selected to avoid
> getting 26 separate emails each day. If I click the "Reply" button
> from the web page I can not attach any files since the web pages do
> not not have this capability. I must use a separate email program,
> client or web-based using the thread's title as the email's Subject
> line.
That is the problem, you cannot reply to individual messages by using
the digest. The digest is one email with its own header. The digest is
mostly for people that just want to read up and follow whats going on
and not participate.
You need to receive the original individual email messages so that you
can reply to them and preserve the message threading.
Google groups may try to make the threading work by checking the
message title but that is not a standard behavior of email.
Anyway, this is way OT so this will be my last reply
Cody