I apologize, I mistake
The BSP_GETVERSION works, I had send the wrong command
The BSP_Exit works only if the filmed is on play
The following code works well in 0.86.501, but not in 1.0.800 (not exit)
repeat
hWnd2 := FindWindow('BSPlayer',nil);
Application.ProcessMessages;
if Time - Te > 1/24/60 then begin
TempoOK:=false;
hWnd2:=1;
end;
until hWnd2<>0;
if tempoOK then begin
Ver := SendMessage(hWnd2, WM_BSP_CMD, BSP_GETVERSION, 0);
SendMessage(hWnd2, WM_BSP_CMD, BSP_Play, 0);
SendMessage(hWnd2, WM_BSP_CMD, BSP_Exit, 0);
end
This you instead work well in both the versions
repeat
hWnd2 := FindWindow('BSPlayer',nil);
Application.ProcessMessages;
if Time - Te > 1/24/60 then begin
TempoOK:=false;
hWnd2:=1;
end;
until hWnd2<>0;
if tempoOK then begin
Ver := SendMessage(hWnd2, WM_BSP_CMD, BSP_GETVERSION, 0);
showMessage(IntToStr(ver));
SendMessage(hWnd2, WM_BSP_CMD, BSP_Play, 0);
SendMessage(hWnd2, WM_BSP_CMD, BSP_Exit, 0);
end
This code starts the Chapter Cap with 0.86.501 and the chapter Cap-1 in 1.0.800
for t:=1 to Cap do SendMessage(bsp_hand,WM_BSP_CMD,BSP_NextCh,0);
|