Search found 24 matches

by Lucky4Me
22 Oct 2024 08:47
Forum: DOS Batch Forum
Topic: Why here echo double times?
Replies: 4
Views: 74678

Re: Why here echo double times?

put an exit /b or goto :eof between the for /f and :ManualRepl for /f "tokens=1-12 delims=," %%A in (C:\CATA_AUTO\ata-master\BVT\BVTTAG\FAPS\%TC_ID%.txt) do call :ManualRepl %%A %%B %%C %%D %%E %%F %%G %%H %%I %%J %%K %%L exit /b :ManualRepl for /f "tokens=1-12 delims=," %%A in (C:\CATA_AUTO\ata-mas...
by Lucky4Me
03 Oct 2024 08:25
Forum: DOS Batch Forum
Topic: how do i display empty lines with maybe DELIMS and TOKENS for TYPE command?
Replies: 6
Views: 12664

Re: how do i display empty lines with maybe DELIMS and TOKENS for TYPE command?

This is your f9.txt

Code: Select all

1
2
3

5

7
8
change the empty lines with the ALT+08 char (BackSpace) and run

For /f "tokens=*" %%a in ('type %k1%') do echo.%%a
by Lucky4Me
29 Aug 2024 08:34
Forum: DOS Batch Forum
Topic: Mass Batch help please
Replies: 2
Views: 27809

Re: Mass Batch help please

@echo off & setlocal enableDelayedExpansion cls & color 0B mode con cols=120 lines=6 cd /d "%~dp0" set "xMkvMerge=C:\Program Files\MKVToolNix\mkvmerge.exe" set "xFFmpeg=C:\ffmpeg\bin\ffmpeg.exe" for %%a in (*.mp4) do ( cls&echo.&echo.&echo Analyzing... %%a "%xFFmpeg%" -i "%%a" -filter_complex "[0:a...
by Lucky4Me
05 Jul 2024 07:29
Forum: DOS Batch Forum
Topic: is there a way to use ECHO <esc>[32;40m without adding an extra line?
Replies: 4
Views: 24697

Re: is there a way to use ECHO <esc>[32;40m without adding an extra line?

one goes with" Press any other key to CONTINUE"
the other goes "Press any other key to QUIT"
Maybe you can adjust your txt to

Code: Select all

echo Press any other key to [32mCONTINUE[0m
Then CONTINUE will be green and the rest will have the default color.
by Lucky4Me
05 Jul 2024 03:39
Forum: DOS Batch Forum
Topic: is there a way to use ECHO <esc>[32;40m without adding an extra line?
Replies: 4
Views: 24697

Re: is there a way to use ECHO <esc>[32;40m without adding an extra line?

You can try the following? @echo off cls call :necho "[32m" "==================" call :necho "[36m" "Quake 4 - selector" call :necho "[32m" "==================" exit /b :necho set "txt=%~1%~2[0m" echo %txt% exit /b Make sure that the color and the txt is between "", then the color becomes %~1 and th...
by Lucky4Me
06 Oct 2023 15:27
Forum: DOS Batch Forum
Topic: I'd like to start Filezilla on a network PC
Replies: 5
Views: 18514

Re: I'd like to start Filezilla on a network PC

Use robocopy, if you want to transfer files from a remote pc to a local pc, or create a share, remote pc is in your own lan.

enter robocopy /? in a cmd window, gives you the options to use
by Lucky4Me
06 Oct 2023 08:46
Forum: DOS Batch Forum
Topic: I'd like to start Filezilla on a network PC
Replies: 5
Views: 18514

Re: I'd like to start Filezilla on a network PC

Check this https://learn.microsoft.com/en-us/sysinternals/downloads/psexec and then try to run the command as follows @Echo On CHCP 65001 SETLOCAL ENABLEEXTENSIONS SETLOCAL ENABLEDELAYEDEXPANSION set USERNAME=docfxit SET /P PASSWORD="Enter the user password: " ECHO. ::net use * /d /y ::net use Z: \\...
by Lucky4Me
17 Jun 2023 13:37
Forum: DOS Batch Forum
Topic: Script issue on "FINDSTR"
Replies: 7
Views: 6054

Re: Script issue on "FINDSTR"

This is what i get C:\>REG QUERY "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" | findstr ProductName ProductName REG_SZ Windows 10 Pro C:\>wmic os get Caption Caption Microsoft Windows 10 Pro C:\>systeminfo|find /i "os name" OS Name: Microsoft Windows 10 Pro C:\>
by Lucky4Me
17 Jun 2023 08:25
Forum: DOS Batch Forum
Topic: Script issue on "FINDSTR"
Replies: 7
Views: 6054

Re: Script issue on "FINDSTR"

Maybe this can help? @echo off REM Check the OS version for /f "tokens=3-5 delims= " %%i in ( 'REG QUERY "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" ^| findstr ProductName' ) do set "winversion=%%i %%j %%k" if "%winversion%" == "Windows 10 Enterprise" ( set "install_folder=\\server\share\Ent...
by Lucky4Me
17 Jun 2023 07:16
Forum: DOS Batch Forum
Topic: Script issue on "FINDSTR"
Replies: 7
Views: 6054

Re: Script issue on "FINDSTR"

Have you run "wmic os get Caption" in a DOS window on the PC?
Because when i run it i'll get "Microsoft Windows 10 Pro" not "Microsoft Windows 10 Professional" and that's a great difference!
by Lucky4Me
18 Mar 2023 11:41
Forum: DOS Batch Forum
Topic: [SOLVED] Unable to rework working script due to name of folder and / or removal of sign -
Replies: 7
Views: 8938

Re: Unable to rework working script due to name of folder and / or removal of sign -

C:\q\! SCRIPTS>
is this your working path?

make a working path "c:\q\Scripts" and try your batch again in this directory.
by Lucky4Me
18 Mar 2023 06:09
Forum: DOS Batch Forum
Topic: [SOLVED] Unable to rework working script due to name of folder and / or removal of sign -
Replies: 7
Views: 8938

Re: Unable to rework working script due to name of folder and / or removal of sign -

Try it this way, I put echo 1) ... , in the script, then you can see what the outcome is and maybe you can see the problem where it breaks? Sometimes a username with a space in can break things! @echo off setlocal enabledelayedexpansion for /f "tokens=1-3 delims=/" %%A in ('powershell -command "Get-...
by Lucky4Me
20 Jan 2023 10:36
Forum: DOS Batch Forum
Topic: Issues with my progress bar
Replies: 3
Views: 10283

Re: Issues with my progress bar

Make sure that all your variables are set correct and used correct! @ECHO OFF MODE CON: COLS=150 LINES=50 CHCP 65001 REM.-- Preparando processador de comandos SETLOCAL ENABLEEXTENSIONS SETLOCAL ENABLEDELAYEDEXPANSION ECHO. ECHO [92mCriando Estruturas de pastas...[0m ::Operations with progress bar ::...
by Lucky4Me
17 Jan 2023 06:08
Forum: DOS Batch Forum
Topic: Specific Multiple delete
Replies: 6
Views: 16098

Re: Specific Multiple delete

try this one

Code: Select all

for /r "YOUR DRIVE AND MAP" %%g in (*.xml,*.zip) do (del /q /f %%g)
change YOUR DRIVE AND MAP into "E:\PC1-HOME\export\corrupted" and adjust the extensions you want to delete. Seperate extensions with a ,
by Lucky4Me
17 Jan 2023 05:55
Forum: DOS Batch Forum
Topic: How to [automatically] rename a file within a non-specified subfolder? [AKA stopping Opera from autoupdating]
Replies: 6
Views: 14872

Re: How to [automatically] rename a file within a non-specified subfolder? [AKA stopping Opera from autoupdating]

Try the next code @for /F "tokens=1,2,3,4 delims=/ " %%A in ('Date /t') do @( set Month=%%B set Day=%%C set Year=%%D set now=%%B%%C%%D ) for /f %%i in ( 'dir "%LocalAppData%\Programs\Opera\" /B /AD ^|findstr /r [0-9]' ) do ( if exist "%LocalAppData%\Programs\Opera\%%i\opera_autoupdate.exe" ren "%Loc...