Unzip from 139 file

Microsoft Windows server 2003 enterprise
December 23, 2009 at 01:12:04
Specs: Win Server 2003, intel
HI ,

I have some 1000 .Zip files in a folder , I have to Unzip the file starting from 139th file via batch script.

Please let me know how can I do this.

Thanks


See More: Unzip from 139 file

Report •


#1
December 23, 2009 at 01:32:21
from 139th

As defined by WHAT? newest, oldest, funniest


=====================================
Helping others achieve escape felicity

M2


Report •

#2
December 23, 2009 at 01:48:52
HI ,

I am sorry , I didn't mentioned the .zip file names.
CDR_EDWLOAD_139.Zip
CDR_EDWLOAD_140.Zip
CDR_EDWLOAD_141.Zip
to
CDR_EDWLOAD_1000.Zip

I have unzip this by file name.

Thanks


Report •

#3
December 23, 2009 at 02:11:52
Are the numers below 11 also 3 digit?

like:

CDR_EDWLOAD_041.Zip


=====================================
Helping others achieve escape felicity

M2


Report •

Related Solutions

#4
December 23, 2009 at 03:28:12
Try something like this:

for /l %%i in (139 1 1000) do unzip CDR_EDWLOAD_%%i.Zip


Report •

#5
December 23, 2009 at 03:49:52
Hi klint,

Nice one. I was about to make it much harder.


=====================================
Helping others achieve escape felicity

M2


Report •

#6
December 23, 2009 at 04:14:10
Like that as well Klint, can't be simplier.

But, what happens if the question would be, from 39 to 1000, and knowing that we use "039", not "39", a bit like Mechanix is referring to in Response nr. 3 ?


Report •

#7
December 23, 2009 at 04:36:38
You wind up having to pad/unpad, I guess.

But maybe klint has another smooth move.


=====================================
Helping others achieve escape felicity

M2


Report •

#8
December 23, 2009 at 04:41:33
Klint has many smooth moves

Having to pad is a given, just wanting to know how to


Report •

#9
December 23, 2009 at 05:52:20
I did this a while back:

========================
@echo off
setLocal EnableDelayedExpansion

:main
for /f "tokens=* delims= " %%a in ('dir/b/a-d *.bat') do (
set S=%%~Na
call :sub1
echo ren %%a !S!%%~Xa
)
goto :eof

:sub1
:pad
if !S:~8^,1!'==' set S=0!S!& goto :pad


=====================================
Helping others achieve escape felicity

M2


Report •

#10
December 23, 2009 at 06:36:20
Hi ,

below 100 there are 2 digits file names

CDR_EDWLOAD_41.Zip
CDR_EDWLOAD_38.Zip
CDR_EDWLOAD_11.Zip

Thanks


Report •

#11
December 23, 2009 at 07:54:55
#4 should do it


=====================================
Helping others achieve escape felicity

M2


Report •


Ask Question