Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 209
Default Please help with do while

Hi
I use this in a userform
Do While kur1 <= kur2


Set fso = CreateObject("scripting.filesystemobject")
On Error GoTo delfolder
fso.GetFolder ("c:\" & tt & tal & kur1)

'fso.deletefile "c:\" & tt & tal & kur1 & "\*.*"
fso.deletefolder "c:\" & tt & tal & kur1 & "\*.*"
kur1 = kur1 + 1
Loop
How can i get this to work with my do while easy to say exit sub on error
but there can be other folder der are somthing in so what shall i do here ??

Reagrds Alvin

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 209
Default Please help with do while

Wow I done it
Yes yes yes

Alvin


"Alvin Hansen" skrev:

Hi
I use this in a userform
Do While kur1 <= kur2


Set fso = CreateObject("scripting.filesystemobject")
On Error GoTo delfolder
fso.GetFolder ("c:\" & tt & tal & kur1)

'fso.deletefile "c:\" & tt & tal & kur1 & "\*.*"
fso.deletefolder "c:\" & tt & tal & kur1 & "\*.*"
kur1 = kur1 + 1
Loop
How can i get this to work with my do while easy to say exit sub on error
but there can be other folder der are somthing in so what shall i do here ??

Reagrds Alvin

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 11:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"