Docker cannot find file in image when it is there?

Pretty new to Docker but I am trying to use it to automate building of a layer for a Lambda function from Windows 10.

Currently my Dockerfile looks like this:

FROM lambci/lambda:build-python3.7
ADD . /media/output
RUN pip install dos2unix
RUN python -m dos2unix /media/output/build_layer_docker.sh /root/build_layer_docker_cleaned.sh
RUN chmod +x /root/build_layer_docker_cleaned.sh
RUN /root/build_layer_docker_cleaned.sh

And I have this Batch file:

docker build -t pyodbcbuild .

docker images -q pyodbcbuild > containerId.txt
set /p containerId=<containerId.txt

docker cp %containerId%:/root/pyodbc-layer.zip ./pyodbc-layer.zip
REM docker rm %containerId%

When I run the batch file the container builds fine and does all of the script correctly and creates a file at /root/pyodbc-layer.zip.

However at the cp command it always fails with this:

docker cp 0e56835088ec:/root/pyodbc-layer.zip ./pyodbc-layer.zip Error: No such container:path: 0e56835088ec:/root/pyodbc-layer.zip

When I run the container I can clearly see the file is there? enter image description here