Quick update on my original post. Since I couldn’t find the answer in any other Reddit article on this topic, I’m posting my solution now.
First problem was the GlobalProtect version. For a working script I changed to version 6.1.2.
After that the following values were stored in the registry:
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Palo Alto Networks\GlobalProtect\Settings\post-vpn-connect
Try using quotes in your registry command value. Also try putting in a pause of some sort in the .bat file.
We use the reg key/script for the same purpose and sometimes things don’t fully work when they are evoked while GlobalProtect is connecting or transitioning between connections. Seems like AD/DNS needs a second to catch up.