Recent

Author Topic: SpinEdit OnChange Event Lazarus 1.0.12  (Read 4296 times)

Nitorami

  • Sr. Member
  • ****
  • Posts: 496
SpinEdit OnChange Event Lazarus 1.0.12
« on: January 25, 2015, 09:10:13 pm »
Hi

I'm a beginner with Lazarus.
I am stuck with the behaviour of Misc/TSpinEdit : As expected, the OnChange Event triggers when I click on the SpinEdit, but again when I click somewhere else, e.g. on a RadioButton.
Is there an event which only triggers when I actually CHANGE the number in the SpinEdit ?

Regards
Martin

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #1 on: January 25, 2015, 09:34:55 pm »
Well, my TSpinEdit does not triggers the OnChange event whan I click somewhere else then itself.

Lazarus 1.2.6 r46529 FPC 2.6.4 i386-win32-win32/win64

Win 7

howardpc

  • Hero Member
  • *****
  • Posts: 4144
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #2 on: January 25, 2015, 09:37:44 pm »
Here a change of focus away from a TSpinEdit does not trigger an OnChange, but only an OnEditingDone and an OnExit event.
What is your code that shows an OnChange event occurring?

engkin

  • Hero Member
  • *****
  • Posts: 3112
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #3 on: January 25, 2015, 09:38:28 pm »
It works as expected here as well. I think you need to move to a more recent Lazarus version from yours (1.0.12).

Blaazen

  • Hero Member
  • *****
  • Posts: 3237
  • POKE 54296,15
    • Eye-Candy Controls
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #4 on: January 25, 2015, 09:39:45 pm »
There was bug in past: http://bugs.freepascal.org/view.php?id=21639

I guess you have old version of Lazarus.
Lazarus 2.3.0 (rev main-2_3-2863...) FPC 3.3.1 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

Nitorami

  • Sr. Member
  • ****
  • Posts: 496
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #5 on: January 25, 2015, 09:47:57 pm »
Hi all
Thanks for the quick replies.
@howardpc: I use Memo.Text := ... to show the state of variables.
@Blaazen: I guess this is the issue. Will have to update.

Nitorami

  • Sr. Member
  • ****
  • Posts: 496
Re: SpinEdit OnChange Event Lazarus 1.0.12
« Reply #6 on: January 25, 2015, 10:09:34 pm »
Upgrade to Lazarus 1.2.6 indeed solved the issue... quite a surprise, because, as a newbie, I am programmed to expect the fault on my side :-)

 

TinyPortal © 2005-2018