Cannot Run .BAT file in XY

Things you’d like to miss in the future...
Forum rules
:warnred20: :warnred20: :warnred20: :warnred20: :warnred20: READ THIS AND DO IT!!! :warnred20: :warnred20: :warnred20: :warnred20: :warnred20:

:info: Please include the following information:
1) Your XYplorer Version (e.g., v28.00.0801)
2) Your Windows Version (e.g., Win 11)
3) Your Screen Scaling Percentage (e.g., 125%).

:info: We strongly recommend adding your Windows Version and Screen Scaling Percentage to the Location field in your Profile or to your Signature. That way, you only have to type them once, and we won't have to search for that vital information.

:info: When attaching an Image, please use the Attachment tab at the bottom of your post and click "Add files".

:warnred20: :warnred20: :warnred20: :warnred20: :warnred20: READ THIS AND DO IT!!! :warnred20: :warnred20: :warnred20: :warnred20: :warnred20:
Post Reply
AgentSmith007
Posts: 41
Joined: 06 Oct 2024 18:11
Location: Land of the free, home of the brave

Cannot Run .BAT file in XY

Post by AgentSmith007 »

I just stumble upon bug. May be it is not a bug and I just need to change some settings. I am still learning XYplorer.

Anyway, I have following files in some folder:

1. AVmerge.bat file
2. FFmpeg.exe executable file
3. video.mp4 elementary video stream file
4. audio.aac elementary audio stream file

Here is content of the BAT file:

Code: Select all

ffmpeg.exe -i audio.aac -i video.mp4 -acodec copy -vcodec copy muxed.mp4
When I am in XY I right-click on BAT file and click Run as Administrator, CMD window flashes and nothing happens.
When I use Windows' File Explorer and do the same CMD window opens, process runs, then CMD window closes and I get muxed.mp4 file.

Any thoughts/suggestions?
Rule #39: "There is no such thing as coincidences."

admin
Site Admin
Posts: 66224
Joined: 22 May 2004 16:48
Location: Win8.1, Win10, Win11, all @100%
Contact:

Re: Cannot Run .BAT file in XY

Post by admin »

What if you try the same from the 64-bit context menu? (Configuration | Other | Shell Integration | 64-bit Windows | Show the 64-bit context menu)

highend
Posts: 14940
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: Cannot Run .BAT file in XY

Post by highend »

Won't work either, the .bat will not have the path from where it was executed => Doesn't find anything without a full path for the items to process
One of my scripts helped you out? Please donate via Paypal

PeterH
Posts: 2827
Joined: 21 Nov 2005 20:39
Location: DE W11Pro 24H2, 1920*1200*100% 3840*2160*150%

Re: Cannot Run .BAT file in XY

Post by PeterH »

If you add a pause stmt as last line of the .bat it will not just terminate, so you can have a look on what it says.

AgentSmith007
Posts: 41
Joined: 06 Oct 2024 18:11
Location: Land of the free, home of the brave

Re: Cannot Run .BAT file in XY

Post by AgentSmith007 »

admin wrote: 01 Nov 2024 08:49 What if you try the same from the 64-bit context menu? (Configuration | Other | Shell Integration | 64-bit Windows | Show the 64-bit context menu)
That was already checked.
Rule #39: "There is no such thing as coincidences."

AgentSmith007
Posts: 41
Joined: 06 Oct 2024 18:11
Location: Land of the free, home of the brave

Re: Cannot Run .BAT file in XY

Post by AgentSmith007 »

highend wrote: 01 Nov 2024 10:13 Won't work either, the .bat will not have the path from where it was executed => Doesn't find anything without a full path for the items to process
All four files are in the same folder and it works in Windows' File Explorer.
Rule #39: "There is no such thing as coincidences."

AgentSmith007
Posts: 41
Joined: 06 Oct 2024 18:11
Location: Land of the free, home of the brave

Re: Cannot Run .BAT file in XY

Post by AgentSmith007 »

PeterH wrote: 01 Nov 2024 11:15 If you add a pause stmt as last line of the .bat it will not just terminate, so you can have a look on what it says.
Did that. This is what it says.
ffmpeg.jpg
This is screenshot (1/3 of the CMD window) when I run BAT file using File Explorer.
ffmpeg2.jpg
To see the attached files, you need to log into the forum.
Rule #39: "There is no such thing as coincidences."

Post Reply