Problem solved. use 'command = Calc' to call my Calc function but ignore
the argument passed to it. Create a list with the following elements -
a.get(), b.get() and c.get(). Every time a scale slider is moved, Calc
will retrieve the current scale values and I can do with them whatever I
want...
Matt Hammond wrote:
>> A. Partial success with : command = Calc. A slider will now pass
>> its argument to a function without problem. My Calc function however
>> is expecting 3 arguments - 1 from each slider i.e moving any of the
>> 3 sliders should cause a recalculation. I am now gettin
> A. Partial success with : command = Calc. A slider will now pass its
> argument to a function without problem. My Calc function however is
> expecting 3 arguments - 1 from each slider i.e moving any of the 3
> sliders should cause a recalculation. I am now getting the following
> erro
Matt Hammond wrote:
> On Mon, 22 Aug 2005 12:16:01 +0100, m7b52000 <[EMAIL PROTECTED]>
> wrote:
>
>>> command = lambda : Calc(a.get())
>
>
>> I get the following message when I use lambda as above:
>>
>> TypeError: () takes no arguments (1 given)
>
>
> Oops, forgot! The Scale widget outp
On Mon, 22 Aug 2005 12:16:01 +0100, m7b52000 <[EMAIL PROTECTED]>
wrote:
>> command = lambda : Calc(a.get())
> I get the following message when I use lambda as above:
>
> TypeError: () takes no arguments (1 given)
Oops, forgot! The Scale widget outputs a single argument - the value of
the
Matt Hammond wrote:
> On Sun, 21 Aug 2005 08:09:55 +0100, m7b52000
> wrote:
>
>> It is proving most difficult in Python. How do I pass the .get()
>> values to my calculating function? Do I use the command option for
>> each slider? e.g command = Calc(a.get()). Obviously not cos it
>> doesn
On Sun, 21 Aug 2005 08:09:55 +0100, m7b52000
wrote:
> It is proving most difficult in Python. How do I pass the .get() values
> to my calculating function? Do I use the command option for each slider?
> e.g command = Calc(a.get()). Obviously not cos it doesn't work.
It should work if you w
Some time ago I wrote a little program in Tcl/Tk that took the values
from 3 sliders and performed a calculation using these values. The
calculation was of course automatically repeated each time a slider was
moved.
It is proving most difficult in Python. How do I pass the .get() values
to my