Moin!
So klappt's besser:
Delphi-Quellcode:
If OpenDialog1.Execute Then
Var
lExt: String;
Begin
lExt := ExtractFileExt(OpenDialog1.Filename);
if lExt = '.mp3' then
//als mp3 öffen
if lExt = '.avi' then
//als avi öffen
End;
Da ExtractFileExt() den Punkt mitliefert.
MfG
Muetze1