elk Posted June 18, 2020 Share Posted June 18, 2020 How can I find/replace execute only in a selection or a text chain? I’m woking on a book with 280 pages (which works really fine, btw.). But when it comes to change some things by find/replace i.e. only in one chapter – how can I do that? Showing hundrets of results over the complete text isn’t really handy … Is there a way? I would be glad to hear about it! only7yb 1 Quote Thanks for reading. ................................................................................macOS 10.13.6 | MacBookPro | 2.5 GHz Intel Core i5 | Affinity Suite Link to comment Share on other sites More sharing options...
Seneca Posted June 18, 2020 Share Posted June 18, 2020 3 minutes ago, elk said: Is there a way? I would be glad to hear about it! II don't know of a way to search in a selection. This is an all or nothing action at the moment, I'm afraid. A workaround is to copy your selection to a temporary document, perform find and replace and paste it back. We all hope for great improvements in this area in the future. elk 1 Quote 2017 27” iMac 4.2 GHz Quad-Core Intel Core i7 • Radeon Pr 580 8GB • 64GB • Ventura 13.6.4. iPad Pro (10.5-inch) • 256GB • Version 16.4 Link to comment Share on other sites More sharing options...
walt.farrell Posted June 18, 2020 Share Posted June 18, 2020 It can be done in Publisher, but it's a bit complex and involves using regular expressions. Pick a text string that does not exist in your document, perhaps something like AAAZZZ Insert that string at the beginning of the area you want to search, and also at the end. Thus, your document will have AAAZZZthe text you want to search inAAAZZZ In the Find and Replace panel, click the gear icon for the Find field, and make sure that the Regular Expression option is enabled. As a Find term, use (AAAZZZ.*?)your-find-term(.*AAAZZZ) For Replace with, use /1your-replace-term/2 When you're done, delete both occurrences of AAAZZZ DarkClown, elk, Daniel Gibert and 1 other 3 1 Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. iPad: iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1 Link to comment Share on other sites More sharing options...
elk Posted June 18, 2020 Author Share Posted June 18, 2020 1 hour ago, Seneca said: II don't know of a way to search in a selection. This is an all or nothing action at the moment, I'm afraid. A workaround is to copy your selection to a temporary document, perform find and replace and paste it back. We all hope for great improvements in this area in the future. Simple workaround and somehow better than make it in plain text editor (what I did after writing the post). RalphGL 1 Quote Thanks for reading. ................................................................................macOS 10.13.6 | MacBookPro | 2.5 GHz Intel Core i5 | Affinity Suite Link to comment Share on other sites More sharing options...
elk Posted June 18, 2020 Author Share Posted June 18, 2020 23 minutes ago, walt.farrell said: It can be done in Publisher, but it's a bit complex and involves using regular expressions. Pick a text string that does not exist in your document, perhaps something like AAAZZZ Insert that string at the beginning of the area you want to search, and also at the end. Thus, your document will have AAAZZZthe text you want to search inAAAZZZ In the Find and Replace panel, click the gear icon for the Find field, and make sure that the Regular Expression option is enabled. As a Find term, use (AAAZZZ.*?)your-find-term(.*AAAZZZ) For Replace with, use /1your-replace-term/2 When you're done, delete both occurrences of AAAZZZ This one is a handy workround without leaving the current document. I will try this one. Quote Thanks for reading. ................................................................................macOS 10.13.6 | MacBookPro | 2.5 GHz Intel Core i5 | Affinity Suite Link to comment Share on other sites More sharing options...
Daniel Gibert Posted August 13, 2020 Share Posted August 13, 2020 On 6/18/2020 at 1:14 PM, walt.farrell said: It can be done in Publisher, but it's a bit complex and involves using regular expressions. Pick a text string that does not exist in your document, perhaps something like AAAZZZ Insert that string at the beginning of the area you want to search, and also at the end. Thus, your document will have AAAZZZthe text you want to search inAAAZZZ In the Find and Replace panel, click the gear icon for the Find field, and make sure that the Regular Expression option is enabled. As a Find term, use (AAAZZZ.*?)your-find-term(.*AAAZZZ) For Replace with, use /1your-replace-term/2 When you're done, delete both occurrences of AAAZZZ Thanks for the tip. It will be useful but is far from a perfect solution. I find strange that there is no options to article, selection only search. For the kind of work I do is a tool I use continually. I hope is on the list for future updates. DarkClown 1 Quote Link to comment Share on other sites More sharing options...
only7yb Posted January 17, 2023 Share Posted January 17, 2023 Ohh This workaround doesn't seem to help with searching in a group of separate text frames. Being able to find/replace in selected parts of the document is crucial to my workflow Looking forward to updates in this area Quote Link to comment Share on other sites More sharing options...
charlesbewlay Posted June 12, 2023 Share Posted June 12, 2023 A very simple workaround is to copy and paste the selection into a new Publisher document, search and replace all. Then paste back. Pretty quick, but may not apply to all situations. Affinity needs a fix to this: we're in 2.1 already and that's pretty basic. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.