Input box error message, no recovery

Lee Fisher shared this question 1 week ago
Answered

Apologies for my frequent appearance here.

I seem to have a bug in this file that I can't find.

This applet works fine until the input box gives the 'check your input' error message; for example, typing in '10 +' and not completing the addition. Then the input box does not seem to link any further input to the function as I'm expecting it to.

A fix?

My best idea is to remake the whole applet but I'd like to avoid that.

Thanks

Comments (7)

photo
1

I fixed it, I had thought I could link the input box directly to the function and save a step - as long as something that is not a function is not typed in it was all good.

I've linked the input box to an empty text, and scripted the input box to update the value of the function to the input value with the 'SetValue[f,%0]'

I suppose typing in a non function to the input box with a linked function makes the function undefined and unrecoverable; but the second way the command 'set value' won't take place without a valid function?

photo
1

link the input box directly to the function
That's the ideal solution (then you won't need any scripting). Please post your file if that's not working as you want

photo
1

Hello MIchael - here's an earlier version, the input box is linked directly to 'finp' which is the function graphed with the green broken line. If I type in something such as '10 +' to the input box, the function cannot be updated by the input box thereafter without resetting.

Be glad to hear about a better fix or if I'm missing something.

photo
1

Thanks, that's a bug! Fixed for next release

photo
1

Until the bug is fixed, here is a possible solution that also works with ggb5. I have used a suggestion by rami in https://help.geogebra.org/t... to use a dummy string that gets an update script to catch a possible empty input and parses the string to a function. (In the german geogebra version each call of the parse function inside the conditional created a copy of the function (another bug?), which I avoided by using "Ausführen").

photo
photo
1

I encountered the same problem today. I tried this with several other object (lists, points, angles, etc.) so far the problem only arises with functions.


I will use your solution for functions. Thanks.

photo
1

Your solution only works for my version of ggb6 and not for ggb5. I could not make it work for the web-app either. But perhaps there is another way?

© 2019 International GeoGebra Institute