The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Special Forums > Windows & DOS: Issues & Discussions
.
google unix.com



Windows & DOS: Issues & Discussions All Windows and DOS questions should go here as well. Discuss UNIX to Windows (Desktop or Server) here!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
wildcard in a if cycle elionba82 Shell Programming and Scripting 2 04-18-2008 08:25 AM
CEP vs the hype cycle iBot Complex Event Processing RSS News 0 02-05-2008 06:20 PM
For cycle nagomes Shell Programming and Scripting 3 06-08-2007 05:48 AM
Stopping a command during the cycle chapmana UNIX for Dummies Questions & Answers 7 11-25-2006 05:08 PM
shell cycle mape Shell Programming and Scripting 2 07-14-2006 03:12 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 09-16-2008
osramos osramos is offline
Registered User
  
 

Join Date: Oct 2007
Posts: 21
Need solution for Bat FIle using FOR Cycle

Hi people.

Don't know if you could help me, but here it goes anyway.

I need to search for some directories, and if i for any file founded a must run another Bat file.

Can this be done in DOS ?

Thanks in advance
  #2 (permalink)  
Old 09-18-2008
Smiling Dragon's Avatar
Smiling Dragon Smiling Dragon is offline Forum Advisor  
Disorganised User
  
 

Join Date: Nov 2007
Location: New Zealand
Posts: 921
Post

This guy:
How to write a DOS batch file to loop through files Jim 2.0’s Blog
Has written a pretty good guide to doing this.

I found I got the most useful search output using:
Code:
dir c:\<filename> /B /P /S
(You can specify wildcards in <filename>)
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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




All times are GMT -4. The time now is 03:03 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0