Solved

Windows find command (from command prompt)

Posted on 2014-11-13
5
155 Views
Last Modified: 2014-11-14
From a command prompt I can perform the following command

find "string" *.*

How do I perform a 'find' command on subdirectories, searching all subdirectories from the current directory for the string

Thanks
0
Comment
Question by:Anthony Lucia
  • 3
5 Comments
 
LVL 28

Accepted Solution

by:
Bill Bach earned 125 total points
Comment Utility
The command (originally from Unix/Linux) which can do this is commonly called "grep".  There are several versions of the GREP utility for Windows that you can download (many for free) that can search inside of files.  I would recommend trying out a few downloads and see which one you like.
0
 
LVL 6

Assisted Solution

by:Rob G
Rob G earned 125 total points
Comment Utility
i don't know if this helps or not..
But to search for a specific string value in a command you can use the find /i or find in command..
For instance..

If you do a netstat -aon
and press enter you will get a ton of info, but what if you just want to know what is running on port 80.

you use netstat -aon | find /i "80" and you will get an output of anything with port 80.

This command " | find /i "80" " seems to work with everything, systeminfo, etc.. i am not sure if it will work with what you are trying to do, but it can't hurt to try...
0
 
LVL 28

Assisted Solution

by:becraig
becraig earned 250 total points
Comment Utility
If you just want to do a dir listing and find a string ...
dir | findstr /s /I "string."

Open in new window


/I says case insensitive

the "." represents a wildcard
0
 
LVL 28

Expert Comment

by:becraig
Comment Utility
This can also be done using powershell
gci -path c:\folder -recurse |? {$_.psIsContainer -and $_.name -like "*string*"} 

Open in new window

0
 
LVL 28

Assisted Solution

by:becraig
becraig earned 250 total points
Comment Utility
Seems I forgot the /s in the dir command
dir /s | findstr /s /I "string."

Open in new window

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Outgoing Exchange 2003 Domain Issue 3 10
Help with computer errors 18 118
URL to download Windows 10 Home 2 92
Hibernate on windows 10 18 76
Introduction: I have always been a big fan of Windows but my liking towards it is slowly being eroded by the variety of other Applications that I encounter, when I browse the Web. Most of the software available is free and maybe Open Source too. …
INTRODUCTION The purpose of this document is to demonstrate the Installation and configuration of the Data Protection Manager product. Note that this demonstration was prepared on the basis of Windows OS is 2008 R2 and DPM 2010. DATA PROTECTI…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now