Tagged Questions

Operations that locate specific instances of conditions being met and replacing them.

learn more… | top users | synonyms (1)

0
votes
2answers
78 views

Search and replace text and everything that follows in the same line

How can I search for a certain string in multiple files (with a given extension) in a directory and replace everything afterwards (including the search string) with a blank string? Example I'm ...
19
votes
5answers
21k views

How can I do a recursive find and replace from the command line?

Using a shell like bash or zshell, how can I do a recursive 'find and replace'? In other words, I want to replace every occurrence of 'foo' with 'bar' in all files in this directory and its ...
2
votes
2answers
2k views

How to replace one line to two lines or more on a text file using the “find and replace mode”?

Right now I'm developing a script with vbscript and I need to find one specific line(with a lot of occurrences) on a 5k lines source code and replace it to two new code lines(1 line to 2 lines ...
0
votes
1answer
462 views

Using RegEX To Prefix And Append In Notepad++

I found this question on StackOverflow. It worked great but I also need to include lines that have non-alphabet characters in it like: some_name some.name And add prefixes like this: ...
0
votes
1answer
997 views

Find and Replace text (FART): Replaced 0 occurence(s)

The great FART utility seems to be the norm when trying to replace text on the windows command line. However I can't get it to work as shown in the examples. My test file test.txt: Images Here ...
0
votes
2answers
400 views

search, remove duplicates and marge to one file

What is going to be my best way to search and remove duplicate's from over 50GBs worth of text files and merge them into one? I figure a GUI app will just hang so I need a CLI style with threading ...
1
vote
1answer
1k views

Replace a block of numbers in sed

I've been fiddling with this for a while now and can't seem to figure it out. What I'm trying to do is replace all numbers in a file with a single #. Sounds simple, and it should be, but I can't get ...
0
votes
1answer
543 views

editing PDFs (find and replace ' ')

What method/program could I use to perform a find and replace to turn ' ' into ' ' in a PDF file? I can use either linux or windows solution. EDIT: The addon for OpenOffice Draw to access ...
3
votes
1answer
4k views

Delete all text before and after a certain string

I have some URL like the following http://www.SOMEURL.com/first-category/1343381-example-text-text-text-text-2000-a.html What I want is to simple delete all of the text before and after the number ...
0
votes
0answers
338 views

Implementing find and replace using NPPExec in Notepad++

How do we perform find and replace using NPPExec plugin in Notepad++? Any help (command/resource) in this regard will be greatly appreciated.
3
votes
2answers
314 views

Append lines one after another in notepad++

How do we achieve the following using replace function in notepad++? Transforming the following cow horse elephant camel into 'cow','horse','elephant','camel' I know ^ and $ (under Regular ...
0
votes
2answers
483 views

Notepad++ Find & Replace (with regex) issue

I'm going crazy on a weird issue, I've been trying to find this text: CREATE Proc [dbo].[procName] (@EMI_ID numeric(8), @ESYNTH_ID numeric(8), @FLD_ID numeric(8), @SYNTH_ID numeric(8)) As And I use ...
0
votes
3answers
973 views

Excel or Batch - Trying to Automate Text Correction (Many Changes; One or More Characters Each)

I have a lot of lines of text. I can put them into a text file or into an Excel spreadsheet. They need many changes. Here's an example of a before and after: Input: I'm buying one! Only ...
0
votes
2answers
65 views

Search Replace extended in a html file

i have a little question. I have a big html file and want to replace lots of things inside a lot of times. The only problem i cant solve is a replace with a variable. Example: <image ...
2
votes
1answer
1k views

Removing HTML tags in Notepad++

I'm trying to remove some tags using the Find and Replace feature of Notepad++. What I'm trying to remove for example is <num> and </num>. Right now I'd input <num> and replace it, ...
-1
votes
2answers
258 views

Find and Replace using different keywords

Example. I want to find and replace using: Test1 Test2 Test3 Of course I have to input and click it 3 times in order for me to find and replace using those terms. How do I do it in one shot? Does ...
18
votes
1answer
11k views

Search and replace with TAB character in Sublime Text 2

In Sublime Text 2, I want search and replace by the TAB character. I tried replacing with \t char but it's not working. How can I do it?
1
vote
2answers
3k views

Find and replace block of text (with other blocks of text) in multiple files [closed]

Is there a FREE utility out there for replacing blocks of text? Something like notepad++'s find in files works for simple lines but in my case it's unusable since I need to target the entire block to ...
1
vote
2answers
232 views

replace all names with an alternative using Stream editor (Sed)

I got this question on a task. Nothing works.. Can someone help me? Write a sed script that replace all names with an alternative, search for every words that: Start with a capital, Longer than ...
1
vote
2answers
1k views

Notepad++ RegEx does not work with min and max occurence

I want to find two or more (max 9) white-space characters and replace it with newlines. My RegEx syntax is as follows: [\s]{2,9} However, Notepad++'s RegEx doesn't seem to work with curly braces. ...
5
votes
2answers
2k views

how to do a vim search inverse search for all lines with out text

with grep I can do a grep -v "my search" to get all the lines with out "my search" with sed I can sed '/baz/!s/foo/bar/g' to find replace text on lines with out baz Is there a way to do the same ...
0
votes
1answer
394 views

In MS Access 2008, how do I search for asterisks (*)

As * is a wildcard character that matches any string, it gives me the first row, not the first row containing an asterisks.
1
vote
2answers
2k views

Excel - find and replace images?

I exported a huge page from confluence into excel and it has a few columns that contain images. I need to convert them into text before I do another transition but this would be totally killing to do ...
1
vote
1answer
517 views

Linux shell script: copy a (text) file and replace a token with a path

I need to create a text file where parts of it should be replaced by any arbitrary path. I wanted to do that by copying a template file and then replace a special pattern, e.g. ${MY_PATH} with the ...
0
votes
1answer
193 views

Bulk search and replace [duplicate]

Possible Duplicate: Bulk search and replace I have more than 1000 php files. I need to BULK search and replace a text. I want to search and replace both file content and filenames. Is ...
2
votes
2answers
623 views

How do I replace all WOrds with FAlse SEcond LEtter Capitalization in lots of Word documents?

I need to mass-correct large amounts of documents in German. I need to handle several hundred pages of text. I have written a macro to do mass find-and-replace operations on common spelling mistakes. ...
1
vote
1answer
2k views

Search & replace with wildcards and variable length strings in Notepad++

I am trying to edit a series of strings in Notepad++ using search & replace. What I'd like to do is to search for a particular piece of HTML code, then delete a portion of it. The challenging ...
1
vote
1answer
2k views

How can I remove unicode characters in a Microsoft Word document?

I'm saving a Microsoft Word document as a PDF but it is warning me that there are a few problems including the fact that the document includes Unicode characters. I'm not sure what characters it is ...
5
votes
1answer
308 views

How can I insert a page break using Find/Replace dialog in Word 2007?

I'm trying to replace "----------" with a new page or a CTRL+enter keyboard shortcut. I pasted "CTRL+ENTER" into the "Replace With:" field in Microsoft Word 2007, hoping that when I clicked "Replace ...
1
vote
1answer
314 views

How to replace text using regex with back-referece in Notepad++?

I'm converting Windows batch script .bat to Linux batch script .sh What takes time a lot is to change the way .bat script use variables. i.e. In Windows @set varName=122 echo %varName% In Linux ...
1
vote
3answers
160 views

Windows, selective text search and replace within files? [duplicate]

Possible Duplicate: Editor with muti-line search and replace I'm looking for (ideally free) software, which will perform selective search and replace on multiple text files. So I want to ...
2
votes
2answers
1k views

Textmate: regular expression to replace matches preserving case?

How can I use a single search / replace to replace all words town with village preserving the case of the first letter in this sentence: Towns are small cities. I live in a town.
1
vote
1answer
1k views

How can I insert italics in MS Word Find and Replace?

I've written a long document and just read the branding guidelines that says the 'e' at the start of a word needs to be italicized, e.g. eBahgum, the e is italics and Bahgum isn't. I've written this ...
1
vote
1answer
596 views

Remove unwanted hyphens using “Find & Replace”

How do I remove unwanted hyphens from some text I have copied out of a PDF into Word. The criteria is that I would like to remove any hyphen that does not have a space either to its left or right. ...
-1
votes
1answer
399 views

Linux “rpl” command doesn't replace text

I'm using rpl program in linux to replace date( with pdate( in some files. But it says A Total of 0 matches replaced in 1 file searched. while grep output for date( is: ...
2
votes
1answer
2k views

How can I automate modifying key/value pairs in a shell script?

I often want to automate this sort of task in a shell script: if the line: SOMEKEY=SOMEVALUE exists in a file, then change it to SOMEKEY=SOMEOTHERVALUE otherwise, append the line ...
4
votes
6answers
11k views

Regex Replace from Command line

Is it possible to regex replace from command line? Right now I'm using notepad++ to do this. In command line I can only use FINDSTR wich can only locate the mached files/lines EDIT : Maybe it will be ...
0
votes
1answer
83 views

Find in files list of values

I have a list of values, and I need find each value one by one in a folder (and its sub-folders) with files, and then save the results (list of files for each entry). Is there any tools to do this? ...
0
votes
3answers
346 views

Find and replace character with control character

Is it possible to find and replace a character with a control character? Given the text one,two,three I want to Find , and replace with \n (new line). So the result becomes one two three I am ...
1
vote
1answer
4k views

Replace foreign character codes in Notepad++

I'm trying to edit a file with Swedish characters in Notepad++, but the Swedish characters when I view it in Unicode (was originally ANSI) show up as tiny black marks with parts of hex code in them, ...
1
vote
2answers
706 views

Batch find/replace in text or html files

I have a large collection of html files (thousands), and need to change a single character that wasn't displaying properly on some browsers. Is there a quick and efficient way to do this?
4
votes
1answer
436 views

How to do a search-and-replace in Opera for textarea context?

How do I do a search-and-replace in Opera for a textarea's context? I have a web page with html form and I need to input and edit large text in this form. Easy example: Stay on this page, scroll ...
1
vote
5answers
7k views

Find and replace text in multiple files

I’m hoping someone might lend their time in helping me create a batch file or similar for finding and replacing text in several files. I have tried many “search and replace” utilities but have not ...
0
votes
2answers
187 views

Find and replace all blanks with underscore characters in Windows 7 dialogs, or PDF form dialog

Within Windows 7, I use utilities such as PDFCreator; I would like to locate a keyboard shortcut utility to find all instances of a character (e.g a blank) in a single line dialog form and replace all ...
1
vote
1answer
1k views

Find/Replace Paragraph End (^13) in Microsoft Word 2007 Merges Paragraphs

I need to replace a target at the beginning of lines with something else. Without wildcards, I can say to replace "^pTarget" with "^pReplacement". With wildcards enabled, I use replace "^13Target" ...
9
votes
2answers
11k views

How to find and replace the character “*” in excel

I am trying to find and replace the * (star, or shift+8) character in a bunch of formulas in Excel 2007. * of course matches the ENTIRE contents of the cell, which is not what I want. How do I ...
2
votes
2answers
253 views

Remove colons (:) from illustration index in Microsoft Word 2010?

How can I remove all the : from illustration index in Word 2010? FIG. 2.4: Representação em RDF/XML da FIG. 2.3 27 FIG. 2.5: Ilustração da Utilização do RDF com o RDFS 28 But I need this: FIG. ...
3
votes
1answer
450 views

Linux: Find all occurrences of “string1” in files under a directory and replace them with “string2”

In linux, what's a good way to find all occurrences of "string1" in files under a directory and replace them with "string2"?
0
votes
2answers
293 views

Using sed to replace a *large* number of variables in a file

I have a large number of log files, on a linux box, I need to cleanse sensitive data from before sending to a third party. I have used the below script on previous occasions to perform this task, and ...
7
votes
1answer
15k views

Find and replace in Notepad++ using wildcards/regex

I have a SQL dump with expressions such as youtubehd:2nj6bykw. The 2nj6bykw can also be a different random string. It is always 8 characters long. I want to replace youtubehd:2nj6bykw with just ...