Bonjour,

j'arrive pas correctement a lister format vidéo avec YouTube-dl dans un ComboBox car j'arrive afficher une seule format vidéo voir photo
Nom : Capture.JPG
Affichages : 113
Taille : 14,8 Ko

voici mon code analyse video :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
 
Private StrData As New StringBuilder
Dim out As String() = Nothing
 
Private Sub Analyse()
        Dim AnalyserVideo As New Process With {
            .StartInfo = New ProcessStartInfo With {
                .FileName = "Tools\youtube-dl.exe",
                .Arguments = " -F " & TextBox_URL.Text,
                .UseShellExecute = False,
                .CreateNoWindow = True,
                .RedirectStandardOutput = True,
                .RedirectStandardInput = True,
                .RedirectStandardError = True
            },
            .EnableRaisingEvents = True
        }
 
        AnalyserVideo.Start()
 
        AddHandler AnalyserVideo.OutputDataReceived, Sub(processSender As Object, lineOut As DataReceivedEventArgs)
                                                         StrData.AppendLine(lineOut.Data & Environment.NewLine)
                                                     End Sub
        AnalyserVideo.BeginOutputReadLine()
 
        AddHandler AnalyserVideo.ErrorDataReceived, Sub(processSender As Object, lineOut As DataReceivedEventArgs)
                                                        StrData.AppendLine(lineOut.Data & Environment.NewLine)
                                                    End Sub
        AnalyserVideo.BeginErrorReadLine()
 
        Using Sortie_Input = AnalyserVideo.StandardInput()
            While True
                Threading.Thread.Sleep(500)
                If StrData.ToString.Contains("resolution note") Then
                    out = StrData.ToString.Split(",")
                    ComboBox_Format.Items.AddRange(New String() {out(2)})
                    Dim count = ComboBox_Format.Items.Count
                    ComboBox_Format.SelectedIndex = count - 1
                    Exit While
                End If
            End While
            MessageBox.Show("fini de créer la liste!", "Lecture", MessageBoxButtons.OK, MessageBoxIcon.Information)
        End Using
        AnalyserVideo.WaitForExit()
        AnalyserVideo.Dispose()
    End Sub
Pouvez-vous m'aider a lister tous les format vidéo avec youtube-dl dans un combobox1?
Merci de votre compréhension,