I am using an edit box as a round counter. I would like when the text = 5 or 10 for it to show this message then it does some functions. but even when the round is 5 or 10, i never get this message ERoundChange is the OnChange event for the ERound(edit box) ; Any idea why its not working? I assume i am using Self wrong?
{Check if round is 5 or 10}
//-----------------------------------------------------
procedure TBaseGameForm.ERoundChange(Sender: TObject);
//-----------------------------------------------------
begin
if (self.Text = '5') or (self.Text = '10') then
begin
showmessage('checking stats for gryph locations on round: '+self.Text);
end;
end;
Also I change the round at the beginning of each players turn like so
ERound.Text := inttostr(Strtoint(ERound.Text)Mod 10+1);