F
F
Fat Lorrie2016-05-12 17:39:41
cmd/bat
Fat Lorrie, 2016-05-12 17:39:41

Two scripts with "almost" the same name, one of them has a dot and a suffix. How to call it from another script?

Let 's say SET FILENAME=имя_файла. There are two files in the directory: You
%FILENAME%.cmd
%FILENAME%.local.cmd
need to call the one that is local. I do:
CALL %FILENAME%.local.cmd
I get:

'имя_файла.cmd' is not recognized as an internal or external command, operable program or batch file.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
Fat Lorrie, 2016-07-05
@Free_ze

It was decided corny, the story was like this: two scripts were in the same directory. The script with localsubstituted the necessary arguments and called the second one. So, he called the script on a relative path (in the same folder), while I tried to call him from anywhere and when transferring control, the necessary one was %CD%not found.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question