[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Stack overflow error


Sorry too.
It wasn't a generic statement, I was talking about the Value property and
it's quirks that you were having trouble with.
Value works differently to other properties when sharing the Action name
So you are right in the sense that it's not the case with other properties,
they can all be set individually.
But with the Value property (that your original post dealt with) you cannot.

BruceS


On Sun, 22 Sept 2024 at 09:17, Gianluigi <gradobag@xxxxxxxxxxx> wrote:

> Sorry Bruce,
>
> my last reply only referred to your last statement, which seemed generic.
>
> He didn't want to question your always enlightening answers and your
> infinite greatness as a programmer in the slightest.
>
> Greetings
> Gianluigi
>
> Il 21/09/24 23:55, Bruce Steers ha scritto:
> > What works?  they are all just Buttons in that next example not
> CheckBoxes.
> > And your setting Enabled not the Value in the Click event.
> > A completely different example and properties.
> >
> > If you change them to ToggleButtons then they all set Value true when
> > clicking one..
> > And Set the Value in the Click event instead of Enabled and infinite
> > recursion again, just like the CheckBox.
> >
> > What exactly are you saying is not the case and works because I said if
> > you set the Value property of a CheckBox, not the Enabled property of a
> > Button
> >
> > I'll repeat...
> > Setting the Value property in the Click event will trigger another Click
> > event, recursion
> >
> > Do you have any more problems with your coding?
> >
> > BruceS
> >
> > On Sat, 21 Sept 2024 at 22:29, Gianluigi <gradobag@xxxxxxxxxxx
> > <mailto:gradobag@xxxxxxxxxxx>> wrote:
> >
> >     This is not always the case, in fact the attached code works
> >
> >     Regards
> >     Gianluigi
> >
> >     Il 21/09/24 19:16, Bruce Steers ha scritto:
> >      > Also because they all share the same Action name when setting the
> >     Value
> >      > of one of them they all change.
> >      > So you cannot set one true and all the others False.
> >      >
> >      >
> >      >
> >      > On Sat, 21 Sept 2024 at 18:02, Bruce Steers <bsteers4@xxxxxxxxx
> >     <mailto:bsteers4@xxxxxxxxx>
> >      > <mailto:bsteers4@xxxxxxxxx <mailto:bsteers4@xxxxxxxxx>>> wrote:
> >      >
> >      >     EVERY checkbox has the "check" action and the tato Group.
> >      >
> >      >     so this code..
> >      >
> >      >     Public Sub tato_Click()
> >      >
> >      >        Action["check"].Value = False
> >      >        Last.Value = True
> >      >
> >      >     End
> >      >
> >      >     So Action["check"].Value = False sets EVERYTHING false
> >      >
> >      >     Last.Value = True will fire the tato_Click event again.
> >      >
> >      >     so it infinitely recurses
> >      >
> >      >     BruceS
> >      >
> >      >
> >      >
> >      >
> >      >
> >      >     On Sat, 21 Sept 2024 at 17:21, Gianluigi
> >     <gradobag@xxxxxxxxxxx <mailto:gradobag@xxxxxxxxxxx>
> >      >     <mailto:gradobag@xxxxxxxxxxx <mailto:gradobag@xxxxxxxxxxx>>>
> >     wrote:
> >      >
> >      >         Hi Benoit,
> >      >
> >      >         I was playing a bit with Gambas and I don't understand
> >     why this code
> >      >         gives a stack overflow error
> >      >
> >      >         Regards
> >      >         Gianluigi
> >      >
> >
>
>
>

References:
Stack overflow errorGianluigi <gradobag@xxxxxxxxxxx>
Re: Stack overflow errorBruce Steers <bsteers4@xxxxxxxxx>
Re: Stack overflow errorBruce Steers <bsteers4@xxxxxxxxx>
Re: Stack overflow errorGianluigi <gradobag@xxxxxxxxxxx>
Re: Stack overflow errorBruce Steers <bsteers4@xxxxxxxxx>
Re: Stack overflow errorGianluigi <gradobag@xxxxxxxxxxx>