I need ffprobe to pass the width and height values to ffmpeg as I want it to automatically set the aspect ratio.

This is what I use to see what the rez is so far:

for %%i in ("%~nx1") do (
C:\ffmpeg-4.2.2-win32-static\bin\ffprobe.exe -v error -select_streams v:0 -show_entries stream=width,height -of csv=s=x:p=0 "%%i"
I drag the video file onto the bat file and it will print the width and height in the console. So far, so good, I can see it pulls the values correctly.

But I need to pass it to ffmpeg so I can do a simple division to set the aspect ratio in ffmpeg command:

-aspect: width/height
I dont know how to pass the ffprobe values to ffmpeg.

Help appreciated.