TApplicationEvents -> Memo1
Delphi-Quellcode:
try
...
except
on EZeroDivide do SetMsgZeroDivide;
...
on EMathError do SetMsgMathError;
end;
Eine Mail per Shellexecute versenden (über OL bzw OE).
Delphi-Quellcode:
//uses Shellapi;
procedure TForm1.Button1Click(Sender: TObject);
var
Mail, Betreff, Txt:
String;
begin
// Text aus Memo1 (Bug-Report)
Txt := Stringreplace(Memo1.Text,#13#10,'
%0D',[rfreplaceall]);
Mail := '
sw.entwickler@net.de';
// Zu Adresse
Betreff := '
Report';
ShellExecute(
Handle,'
open',
PChar('
mailto:' + Mail + '
?Subject=' + Betreff + '
&Body=' + Txt),
nil,
nil, 0);
end;