menggunakan IF pada MessageDlg di Delphi
berikut coding nya
if MessageDlg('benar dihapus....', mtError, [mbYes, mbNo], 0) = mrYes then
begin
adoquery2.Active := false;
adoquery2.SQL.Clear;
adoquery2.SQL.Add('aaaaaaaaaaaa');
adoquery2.ExecSQL;
end;
daftar TMsgDlgBtn Value dan return value
mbOK => mrOk
mbCancel => mrCancel
mbYes => mrYes
mbNo => mrNo
mbAbort => mrAbort
mbRetry => mrRetry
mbIgnore => mrIgnore
mbAll => mrAll
mbNoToAll => mrNoToAll
mbYesToAll => mrYesToAll
mbClose => mrClose