Deletemediafile1Click method

Applies to
TForm2

Declaration
procedure Deletemediafile1Click(Sender: TObject);

Implementation

procedure TForm2.Deletemediafile1Click(Sender: TObject);
var src_:String;
begin try
play_snd(1);
if msgbox(Application.Title,'Remove "'+trim(minfo_list.Items.Strings[minfo_list.ItemIndex])+'" from the play-list and form WikiBrowse ?',1,0)=6 then begin
   oxGraphicButton13Click(player_stop1);
   src_:=compile_path(get_ini_params('cache','media'))+'\'+media_file_list.Strings[minfo_list.ItemIndex];
   if fileexists(src_) then begin
      if not SysUtils.DeleteFile(src_) then msgbox(Application.Title,'Unable to remove specified media file, because media file is still in use or you have limited system permissions !',0,3); 
   end;
   update_mmedia_list(compile_path(get_ini_params('cache','media')));
   update_ui_media_component;
   if minfo_list.Items.Count >0 then minfo_list.ItemIndex :=0;
end;
abfApplicationProperties1Restore(Sender);
except
on E : Exception do _log_entry_error(E.ClassName,E.Message,'B70000');
end;End;


HTML generated by Time2HELP
http://www.time2help.com