Code:
procedure TForm1.HotSpotImage1HotSpotClick(Sender: TObject;
HotSpot: THotSpot);
begin
DBEdit31.Text := HotSpot.Name;
if RadioButton2.Checked or RadioButton1.Checked or RadioButton3.Checked then begin
TS := TShape.Create(Self);
TS.Shape := stCircle;
TS.Parent := Panel1;
if RadioButton1.Checked then
TS.Brush.Color := clGreen
else if RadioButton2.Checked then
TS.Brush.Color := clYellow
else if RadioButton3.Checked then
TS.Brush.Color := clRed;
TS.Width := 10;
TS.Height := 10;
TS.Left := StrToInt(DBEdit33.Text);
TS.Top := StrToInt(DBEdit34.Text);
TS.Visible := True;
TS.BringToFront;
Timer1.Enabled := True;
ADOTable4.Last;
ADOTable4.Insert;
ADOTable4.FieldByName('brlok').Value := ADOTable4brlok.AsInteger + 1;
if RadioButton1.Checked then
ADOTable4.FieldByName('boja(vrsta)').Value := 'clGreen'
else if RadioButton2.Checked then
ADOTable4.FieldByName('boja(vrsta)').Value := 'clYellow'
else if RadioButton3.Checked then begin
ADOTable4.FieldByName('boja(vrsta)').Value := 'clRed';
ADOTable4.FieldByName('x').Value := StrToInt(DBEdit33.Text);
ADOTable4.FieldByName('y').Value := StrToInt(DBEdit34.Text);
ADOTable4.Post;
end;
end;
procedure TForm1.HotSpotImage1HotSpotClick(Sender: TObject;
HotSpot: THotSpot);
begin
DBEdit31.Text := HotSpot.Name;
if RadioButton2.Checked or RadioButton1.Checked or RadioButton3.Checked then begin
TS := TShape.Create(Self);
TS.Shape := stCircle;
TS.Parent := Panel1;
if RadioButton1.Checked then
TS.Brush.Color := clGreen
else if RadioButton2.Checked then
TS.Brush.Color := clYellow
else if RadioButton3.Checked then
TS.Brush.Color := clRed;
TS.Width := 10;
TS.Height := 10;
TS.Left := StrToInt(DBEdit33.Text);
TS.Top := StrToInt(DBEdit34.Text);
TS.Visible := True;
TS.BringToFront;
Timer1.Enabled := True;
ADOTable4.Last;
ADOTable4.Insert;
ADOTable4.FieldByName('brlok').Value := ADOTable4brlok.AsInteger + 1;
if RadioButton1.Checked then
ADOTable4.FieldByName('boja(vrsta)').Value := 'clGreen'
else if RadioButton2.Checked then
ADOTable4.FieldByName('boja(vrsta)').Value := 'clYellow'
else if RadioButton3.Checked then begin
ADOTable4.FieldByName('boja(vrsta)').Value := 'clRed';
ADOTable4.FieldByName('x').Value := StrToInt(DBEdit33.Text);
ADOTable4.FieldByName('y').Value := StrToInt(DBEdit34.Text);
ADOTable4.Post;
end;
end;