help with loading an file!!
Posted: 31 Jul 2020 04:40
hello everyone!!
so i want to make a batch file with a batch file.
the file that is going to make a batch file is called (A.bat)
the file that is going to be made is called (B.bat)
so here is the code to *A.bat*
-----------------------------------------------------------------------------------------------------
@echo off
:start
(for /f "tokens=* delims=:" %%L in ('findstr /b ::: "%~f0"') do echo %%L) >B.bat
::: @echo off
::: color f0
::: echo hello
::: pause
-------------------------------------------------------------------------------------------------------
but here is the problem see this code
::: @echo off
::: color f0
::: echo hello
::: pause
i do not want that i want the program to load that code from another file which is going to be called(Package.txt)
so for example *package.txt will have this code:
::: @echo off
::: color f0
::: echo hello
::: pause
and i just run *A.bat* and it will take the code form *package.txt* and create a batch file called *B.bat*
thanks for reading and have a nice day, any help would be appreciated!!!
so i want to make a batch file with a batch file.
the file that is going to make a batch file is called (A.bat)
the file that is going to be made is called (B.bat)
so here is the code to *A.bat*
-----------------------------------------------------------------------------------------------------
@echo off
:start
(for /f "tokens=* delims=:" %%L in ('findstr /b ::: "%~f0"') do echo %%L) >B.bat
::: @echo off
::: color f0
::: echo hello
::: pause
-------------------------------------------------------------------------------------------------------
but here is the problem see this code
::: @echo off
::: color f0
::: echo hello
::: pause
i do not want that i want the program to load that code from another file which is going to be called(Package.txt)
so for example *package.txt will have this code:
::: @echo off
::: color f0
::: echo hello
::: pause
and i just run *A.bat* and it will take the code form *package.txt* and create a batch file called *B.bat*
thanks for reading and have a nice day, any help would be appreciated!!!