'Call command in a batch script
I have a script that adds exceptions to the Java_Exception and it works. The issue is after the script runs, I need it to call another script to run and no matter where I put the command in, It doesnt work.
I am hoping someone can tell me how to modify it so it works. I have tried these forums, google and friends.
echo off
SETLOCAL ENABLEDELAYEDEXPANSION
REM SET EX_PATH="%APPDATA%\sun\Java\Deployment\Security\exception.sites"
SET EX_PATH="%APPDATA%\..\LocalLow\sun\Java\Deployment\Security\exception.sites"
REM Here list the site to register up
SET EX_SITE[0]=http://XXXXXX.XXXXXX.com
SET EX_SITE[1]=http://XXXXXX.XXXXXXX.com:8080
REM ↓ end index is aligned with the registration number of
FOR /L %%i IN (0,1,1) DO (
FINDSTR !EX_SITE[%%i]! %EX_PATH%
IF ERRORLEVEL 1 ECHO !EX_SITE[%%i]!>> %EX_PATH%
)
Call %CD%Davids_Script\Inc\NEW_User.bat
Solution 1:[1]
It is because %cd% does not end with a \. You need to change the call to
call %cd%\Davids_Script\Inc\NEW_User.bat
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Magoo |
