jamessxxoo This appears to be the case where you are supplying the same subnet as the host and a gateway that actually exists. You can pursue the much simpler option instead of following this guide. You don't need the host endpoint and workarounds, and should be able to get it to work using:
$localContainerSubnet="10.189.181.0/24"
$containerGw="10.189.181.1"
$dnsServer="10.220.220.220"
docker network create -d l2bridge --subnet=$localContainerSubnet -o com.docker.network.windowsshim.dnsservers=$dnsServer --gateway=$containerGw -o com.docker.network.windowsshim.enable_outboundnat=true winl2bridge
Should create a l2bridge network that can connect to other VMs, as well as outbound connectivity and DNS resolution.
Then to create a container (e.g. "c1") and attach to the winl2bridge network:
docker run -d --rm --name c1 --hostname c1 --network winl2bridge mcr.microsoft.com/windows/servercore/iis:windowsservercore-ltsc2019
Kurt Schenk thank you, the link has been updated.