Since you posted no details, we don't have the slightest clue how that "youtube player" works.
You will have to implement an event handler for OnClose
on your second form and make sure the video is properly shut down.
i tried to do somthing like that
Delphi-Quellcode:
procedure secondform.FormClose(Sender: TObject; var Action: TCloseAction);
begin
embeddedwb.AssignEmptyDocument;
embeddedwb.Free;
end;
procedure secondform.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
begin
CanClose := True;
Self.Hide;
end;
thats close the video and its sound but i cant open it again until i close the whole app and re open it
note i load youtube player inside tembeddedwb