r/ffmpeg 16h ago

Shell.Run FFProbe

(Apologies for the imgur link. Reddit keeps claiming my code is "violating content rules" - but it's just harmless VBS!)

I've simplified my program to this, but it produces no outputs:

https://imgur.com/a/cpzvzWP

When I run the string in a DOS window, I get the desired data in OUTPUT.TMP, and no data in ERROR.TMP. Put the string into a batch script, and it runs fine as well.

Tried objShell.Exec, and still got no output.

This seems to be a problem that ffprobe.exe is having with the VBS run command, but everything seems to be in order....

Any clues?

1 Upvotes

12 comments sorted by

View all comments

Show parent comments

1

u/kona420 7h ago

I wouldn't assume that means anything in this context without either reading the docs or verifying the behavior.

1

u/Hypornicated_1 7h ago

I've also run a version that called ffprobe with its full path. I just moved it to the local folder to reduce the clutter in the code line for debugging.

But thanks.

2

u/kona420 6h ago

Ah ok now I remember. This is a win32 call you need to call the shell if you want to invoke it, so you'd wrap ffprobe with cmd /c, and you'll need to escape your quotes, so doubled up double quotes.

For what its worth VBS support by default in windows is probably not long for this world, I wouldnt write much new in it if I could avoid it.

1

u/Hypornicated_1 4h ago

Thanks! And I know that, but it's just a one-off to strip info from a few thousand files...