Convert Visio to HTML format
Exporter Visio vers HTML
This article explains how to export a Microsoft Visio diagram to HTML using Aspose.Diagram for Python via Java API.
Use the Diagram class constructor to read the diagram files and the Save method to export the diagram to any supported image format. Developers can save resultant HTML in the local storage or directly to a stream instance.
L’image ci-dessous montre unVSD fichier about to be saved to PNG format. You can use other diagram formats (VSDX, VSTM, VSTM, VSSX, VSS, VSSM, VDX, VST, VSTX, VDX, VTX or VSX) as well.
Entrez diagram.
In order to export VSD diagram to HTML, perform the following steps:
- Créez une instance de la classe Diagram.
- Call the Dagram class' Save method and set HTML as the output format.
L’image ci-dessous montre le fichier de sortie HTML.
Output HTML diagram.
Save resultant HTML in the local storage
Le fichier résultant peut être enregistré en transmettant une chaîne de chemin complète, y compris le nom de fichier et l’extension, par exemple @“c:\temp\MyOutput.html”.
Save Resultant HTML in Local Storage Programming Sample
Save resultant HTML in a stream instance
It is for use case to save the resultant HTML in a database or repository without storing it in the local storage. This feature also embeds other resultant resources of the HTML, e.g. fonts, CSS (containing the style information) and images. Since it saves a single HTML file into the stream instance.