Replacing Hyperlink text over multiple paragraphs

Hello Aspose,

We are using code to find hyperlinks in the Word document and are replacing the text of the link.
The code we are using doesn’t work if the hyperlink spreads over multiple paragraphs and I was looking for the options to resolve this. Do you have a newer example that does allow the hyperlink to be over multiple paragraphs ?
And If we would change the example to also check the next paragraphs to find the end node off the hyperlink, are there some issue we could expect ?

An Example of the code can be found in in another thread and was somewhere in the docs.

An example of the document that has hyperlinks spanning multiple is in the attachment. It happens on the links: “How to perform a QESH feasibility check” AND “Securing recipe information for R&D samples”.
ExampleDocument-LinkMultipleParafs.zip (30.7 KB)

Regards,
Jeroen

@inceptionEhv

Please use the following code example to change the address of hyperlink that spans over multiple paragraphs. Hope this helps you.

Document doc = new Document(MyDir + "ExampleDocument-LinkMultipleParafs.docx");
foreach (Field field in doc.Range.Fields)
{
    if (field.Type == FieldType.FieldHyperlink)
    {
        FieldHyperlink hyperlink = (FieldHyperlink)field;
        if (hyperlink.Result == "How to perform a QESH \r \rfeasibility check")
        {
            hyperlink.Address = "https://forum.aspose.com/";
        }
    }
}
doc.Save(MyDir + "21.1.docx");