入门
Contents
[
Hide
]
系统要求
Aspose.Diagram for Python via .NET is platform-independent API and can be used on any platform (Windows and Linux) where Python已安装。
Python版本
- Python 3.6 或更高版本
安装
Windows:
You can easily use Aspose.Diagram for Python via .NET from pypi使用以下命令。
$ pip install aspose-diagram-python
Linux:
You can easily use Aspose.Diagram for Python via .NET from pypi使用以下命令。
$ pip install aspose-diagram-python
Creating the Hello World Application
- 创建一个名为CreatingNewVisioFile.py并使用以下示例代码:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import aspose.diagram | |
from aspose.diagram import * | |
#// Initialize a Diagram class | |
diagram = Diagram() | |
#// Save diagram in the VSDX format | |
diagram.save("CreateNewVisio_out.vsdx", SaveFileFormat.VSDX) |
- 现在将上面的代码保存到“CreatingNewVisioFile.py”并运行“python CreatingNewVisioFile.py”@命令提示符。