All, anyone any idea how to replace the ‘ character (may be others) with no character ie delete all instances from a section of text in code.
I tried it with the search and replace, using the editor facility, and it wouldn’t locate the character. So I’m thinking maybe programmatically turn I’ve to I’ve or that’s to that’s.
All, got round my problem - I had conflicting end of string data in an array when storing processed strings, I tried replacing “‘“ with ‘“‘ for the string start and end delimiters and it worked. But, it still doen’t Help with the issue of not being able to search/replace these characters in the editor.
@Bri_G typing " from the keyboard into the search is a different character from the " displayed in the editor. The search uses the ‘smart’ quotes and the editor doesn’t.
Create a blank new project, highlight and copy the “Hello World!” text on line 5. Hit search and paste this into the search - it finds it. Hit replace and type “Hello World!” in the replace box. Accept the pop up. Codea doesn’t like the new ‘smart quotes’ hello world and flags an error.
You’ve already got a workaround so great. Unfortunately a further complication with your original question is that you can’t search for a single character
@West - thanks for the feedback, the little gem about searching for single characters is useful. Still puzzled though, I tried searching for It in the code and it found several entries, but when I tried It’ it found none. Seems to be the character that is not searchable.
Sorry I can’t be of more help. I did come across a similar issue in a different field of displaying web content - in this case it was copying and pasting from Word into a flat html file and it didn’t like quotes, apostrophe’s and hyphens but the search and replace was straightforward
@West - thanks anyway, managed to resolve it by intuitive fiddling. So now onto the next stage.