[Gambas-user] Problem with finished Shell Process.State <> Process.Stopped
Jussi Lahtinen
jussi.lahtinen at gmail.com
Mon Feb 27 01:01:40 CET 2023
There is a bug in your code, this line makes no sense: "If pYtDlp And If
pYtDlp.Running Then"
Process.Running is constant with integer value 1. So, it is logically
always true.
Jussi
On Sun, Feb 26, 2023 at 10:20 PM T Lee Davidson <t.lee.davidson at gmail.com>
wrote:
> I am creating a project that uses yt-dlp to download media from Youtube.
>
> The project uses the Process = Shell [command] For Read as "Process"
> syntax because I want to track and display the progress.
>
> Downloads work well, but the Process never goes to Process.Stopped state.
> It works well on the command line and exits with code=0.
>
> There is a trap in the Form.Close event to prevent closing the application
> while a download is in progress. I always have to
> choose to abort the Process even though it is finished.
>
> Is this expected behavior, a bug, or my misunderstanding of Process?
>
> Demo attached.
>
>
> --
> Lee
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20230227/395ef194/attachment.htm>
More information about the User
mailing list