Macro to change lyrics?

I am inputting the lyrics in Dorico files for a non-English hymnal. There is some debate as to whether an en dash or em dash or double em dash is best used in the lyrics. The professional editors will have to come to a conclusion, but I can’t wait on them.
If I consistently use an en dash, is there a way to use a macro to change all en dashes to, say, em dashes only in the lyrics? (I am using en dashes in the text boxes with the author data, and I will not want those to be changed.)
There will likely be close to 200 files… changing them individually would be a pain.

There’s no good way to automate this at the moment, I’m afraid. You could do it using the Edit Line of Lyrics dialog, which shows all the lyrics in a window and allows you to edit them there, but you’d still have to do that separately for each line of lyrics in each project.

I do have the vague hope that at some point we can implement a way of updating text items in the project by using the new File > Export > Text feature to export a CSV file of all the text, then have a means of importing this back into the project, so you could make the changes in the CSV file and then reimport them. However, even that would only work one project at a time, so without a more general way of handling batch tasks in Dorico, which is quite a big (though important) job for us, you’re a bit stuck.

The question is (if the need for a change arises at all) whether it is easier to change all and edit the author data or the lyric data.

Is there some reason why the target language would not use a hyphen between syllables?

Eric is problably referring to standard em dash usage as punctuation, not hyphenation.

We are using the hyphen to break syllables. The question is about which dash character to use in punctuating the lyrics as it would be done in poetry not embedded in a musical score.

Thanks for your reply, Daniel.
I was hoping someone would at least say one could open the .dorico files with a text editor and change all en dashes to, say, em dashes if they occurred between certain markers.
In any case, it will be a finite number of files, so it can be done manually, if need be.

I guess export to musicxml, do the change, import musicxml is not an option?
(if the .dorico file format is not xml based)

You might loose some information in the musicxml import/export cycle, but atleast you probably would have an xml format to automate lyric changes with

You’d lose basically all of the formatting work you’d already done if you export and re-import MusicXML, so I really don’t think that’s a good approach.