Rimuovere i collegamenti ipertestuali da Word usando C#

Questo articolo descrive come rimuovere i collegamenti ipertestuali da Word usando C#. You will get details on setting up the development environment, step-by-step instructions, and sample code that shows how to remove hyperlinks from a Word document using C#. You can also improve the provided sample code to create a custom output document.

  1. Configure the IDE to use Aspose.Words for .NET to remove hyperlinks.
  2. Upload the original Word file that contains the hyperlinks in the object Document.
  3. Find all the hyperlinks in the document, skipping those in the summary if necessary.
  4. Store the text displayed by each hyperlink.
  5. Rimuovi i collegamenti ipertestuali e mantieni il testo del collegamento così com’è
  6. Remove the blue color, the underline, and the hyperlink style from that text.
  7. Remove the hyperlink appearance from any other text that still uses it.
  8. Save the updated Word file and view the number of removed hyperlinks.

Questi passaggi descrivono come rimuovere tutti i collegamenti ipertestuali in Word usando C#. Carica il file Word di origine, trova tutti i collegamenti ipertestuali nel documento eccetto quelli nell’indice, e memorizza il testo utilizzato da ciascun collegamento. Rimuovi tutti i collegamenti ipertestuali mantenendo il testo del collegamento, e rimuovi il colore blu, la sottolineatura e lo stile di collegamento ipertestuale prima di salvare il file Word di output.

This code demonstrates how to remove all hyperlinks in Word at once using C#. You can filter hyperlinks by destination address to remove only external web links or links to a specific domain. There is also an option to remove links attached to images and shapes because the sample code only handles text hyperlinks.

Questo articolo spiega il processo di ricerca e rimozione dei collegamenti ipertestuali mantenendo il testo in formato normale. Per lavorare con le revisioni dei documenti e accettare tutte le modifiche in un file Word, consulta l’articolo Accetta tutte le modifiche in Word usando C#.

 Italiano