aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes How to search a file which contains the string either *= or =* Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "How to search a file which contains the string either *= or =*" Watch "How to search a file which contains the string either *= or =*" New topic
Author

How to search a file which contains the string either *= or =*

sumanta panda
Ranch Hand

Joined: Jun 23, 2008
Posts: 224
Dear All,
I am using the Eclipse tool.I want to search a file in my application which contains the String either *= or =*.

But when i use context text: *= and file name: *.java then it search a file which contains = ,* and *= string.
But i want to search a file which should contains only *= or =*.

Please suggest me for the needful.

Please let me know in case of any concerns.

Thanks in Advance.

Regards
Sumanta Pand
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15632
    
  15

You could set up a regular expression search, but for this problem, it's probably just as easy to do 2 regular searches, one for "*=" and one for "=*".

Go to the "File Search" tab on the search dialog. See the text below the "Containing Text" input? Where it says "(* = any string, ? = any character, \ = escape for literals: * ? \)"?

They're not joking.

Enter "\*=" to search for "*=". enter "=\*" to search for "=*".


Customer surveys are for companies who didn't pay proper attention to begin with.
sumanta panda
Ranch Hand

Joined: Jun 23, 2008
Posts: 224
Dear Mr. Tim,
Thanks for your help.Now its working properly.

Best Regards,
Sumant Panda
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to search a file which contains the string either *= or =*
 
Similar Threads
How String tokeinzer is advantegous then Strings utility method
string to be replaced in a file
find
B&S: How to know which record in search Jtable is selected
Highlight the words in files( doc, excel, pdf etc) using java