Search found 250 matches
- 28 Nov 2017 14:10
- Forum: DOS Batch Forum
- Topic: How to set up root directory ?
- Replies: 9
- Views: 6228
Re: How to set up root directory ?
Thanks a lot! Steffen I think I know how to use %~dp0 now But how I can use the sister folders as scripts folder, here is my code the script is currently in ..\Scripts\scheme_replace\ folder Here is the code @ECHO OFF call "%~dp0\get_src.cmd" call "%~dp0\app_var.cmd" ::sdrv is you network mapping dr...
- 28 Nov 2017 09:30
- Forum: DOS Batch Forum
- Topic: How to set up root directory ?
- Replies: 9
- Views: 6228
Re: How to set up root directory ?
Thanks Steffen! I should explain more precisely. Since I have a lot commands to use the absolutely path in my script, for example, I might call one command which path looks like this call C:\auto_pkg_build\Tools\PACKAGER\scheme_replace.cmd or cd C:\auto_pkg_build\Scripts\scheme_replace\pkg_data\temp...
- 27 Nov 2017 15:37
- Forum: DOS Batch Forum
- Topic: about if statement
- Replies: 4
- Views: 3709
Re: about if statement
Thanks Squashman!!
I have a new requirement for this piece code now. So please ignore this topic for now. I might post a new topic later soon if i can not figure it out by myself...
goodywp
I have a new requirement for this piece code now. So please ignore this topic for now. I might post a new topic later soon if i can not figure it out by myself...
goodywp
- 27 Nov 2017 15:22
- Forum: DOS Batch Forum
- Topic: How to set up root directory ?
- Replies: 9
- Views: 6228
How to set up root directory ?
Hi all, I have my tools located in C drive as below I have all my code and source under the folder of auto_pkg_build C:\auto_pkg_build\Scripts C:\auto_pkg_build\Sources C:\auto_pkg_build\Tools C:\auto_pkg_build\Workspace This is my local but if my colleague want to install somewhere in his/her PC un...
- 27 Nov 2017 14:55
- Forum: DOS Batch Forum
- Topic: what cause this ott: ------ after run a script
- Replies: 4
- Views: 3796
Re: what cause this ott: ------ after run a script
Thanks! you are right it was from srcfg.cmd.
I redo the job and works fine now....
I redo the job and works fine now....
- 20 Nov 2017 15:35
- Forum: DOS Batch Forum
- Topic: what cause this ott: ------ after run a script
- Replies: 4
- Views: 3796
what cause this ott: ------ after run a script
Hi, Anyone know what cause this happen? When I ran a script and I got what I expected but at the beginning shows this as below, I can ignore but I would rather to know what was the cause.... >var2cfg.cmd (just after I ran this script, see code below) the following was displayed on the screen at the ...
- 17 Nov 2017 15:32
- Forum: DOS Batch Forum
- Topic: Why this condition clause does not work as expected?
- Replies: 5
- Views: 3972
Re: Why this condition clause does not work as expected?
Thanks Squashman
- 17 Nov 2017 14:33
- Forum: DOS Batch Forum
- Topic: Why this condition clause does not work as expected?
- Replies: 5
- Views: 3972
Re: Why this condition clause does not work as expected?
Finally figured it out as this and it works for /f %%i in ("fk.txt") do set sizei=%%~zi for /f %%j in ("fk_found.txt") do set sizej=%%~zj if %sizei% gtr 0 ( if %sizej% gtr 0 ( type fk.txt|findstr /vig:fk_found.txt >>missed_fk_schemes.txt ) ) if %sizei% gtr 0 ( if %sizej% equ 0 ( type fk.txt >>missed...
- 17 Nov 2017 10:26
- Forum: DOS Batch Forum
- Topic: about if statement
- Replies: 4
- Views: 3709
Re: about if statement
Thanks Squashman!
- 17 Nov 2017 10:19
- Forum: DOS Batch Forum
- Topic: Why this condition clause does not work as expected?
- Replies: 5
- Views: 3972
Why this condition clause does not work as expected?
I have following code to do the job as 1) When fk.txt not empty, and filter the missing ones from the comparison between fk.txt and fk_found.txt and output to missed_fk_schemes.txt 2) When fk.txt not empty, but fk_found.txt empty, then just type fk.txt to missed_fk_schemes.txt call C:\auto_pkg_build...
- 13 Nov 2017 16:13
- Forum: DOS Batch Forum
- Topic: about if statement
- Replies: 4
- Views: 3709
about if statement
I have following code: :: MOCKUP FIND /i "-08699-" <sch_pack.txt >>all_sch_pack.txt :: QA_Infra FIND /i "-08700-" <sch_pack.txt >>all_sch_pack.txt :: NAR_Infra FIND /i "-08680-" <sch_pack.txt >>all_sch_pack.txt :: MY_Prof FIND /i "-02220-" <sch_pack.txt >>all_sch_pack.txt if %errorlevel% equ 1 ECHO ...
- 08 Nov 2017 08:59
- Forum: DOS Batch Forum
- Topic: how to select some row values of one column based upon a txt file
- Replies: 4
- Views: 3464
Re: how to select some row values of one column based up a txt file
Thanks Squashman!!! The option 2 is the exactly one I need. I was thinking to use the last four digits as a search criteria to do the job. But it came out the one you mentioned which should be excluded... Instead, it is better to use the whole strings in column 1 to get the corresponding rows in col...
- 07 Nov 2017 16:11
- Forum: DOS Batch Forum
- Topic: how to select some row values of one column based upon a txt file
- Replies: 4
- Views: 3464
Re: how to select some row values of one column based up a txt file
What I want to match is the last four digits which is the version in criteria.txt
- 07 Nov 2017 14:18
- Forum: DOS Batch Forum
- Topic: how to select some row values of one column based upon a txt file
- Replies: 4
- Views: 3464
how to select some row values of one column based upon a txt file
I have a task to select certain row values of one column from a txt file 1) I have a criteria.txt T501-08667- 0102 T501-08696- 0101 T501-08657- 0101 2) I have another txt file (profile_scheme.txt) which has four column as below: T501-08667-0100, T501-08680-0100, T501-08815-0100, T501-08665-0100 T501...
- 31 Oct 2017 12:40
- Forum: DOS Batch Forum
- Topic: how to delete files of within folders with same name as files based upon a list of files
- Replies: 4
- Views: 3514