Speichern Sie eine JSON-Datei unter PNG in Python
API
POST
https://api.aspose.cloud/v3.0/cells/{name}/SaveAs
Das Speichern von Dateiformaten aus JSON als PNG ist eine komplexe Aufgabe. Alle Formatübergänge von JSON in das Format PNG werden von unserem SDK Python durchgeführt, wobei der strukturelle und logische Hauptinhalt der Quell-JSON-Tabelle erhalten bleibt. Unsere Python-Bibliothek ist eine professionelle Lösung, um JSON als PNG-Dateien online zu speichern. Dieses Cloud SDK bietet Python Entwicklern leistungsstarke Funktionalität und eine perfekte PNG Ausgabe.
Python Codebeispiel zum Speichern von JSON als PNG mit REST API
# For complete examples and data files, please go to https://github.com/aspose-cells-cloud/aspose-cells-cloud-python/
cells_api = CellsApi(os.getenv('ProductClientId'),os.getenv('ProductClientSecret'))
name ='Book1.json'
saveOptions = None
newfilename = "Book1Saveas.png"
isAutoFitRows= True
isAutoFitColumns= True
folder = "PythonTest"
saveResponse = cells_api.cells_save_as_post_document_save_as(name,save_options=saveOptions, newfilename=(folder +'/' + newfilename),folder=folder)
So speichern Sie JSON als PNG mithilfe der Cells Cloud Python-Bibliothek.
- Registrieren Sie ein Konto unterArmaturenbrett um ein kostenloses API-Kontingent und Autorisierungsdetails zu erhalten
- Installieren Sie die Bibliothek Python und fügen Sie die Referenz (importieren Sie die Bibliothek) zu Ihrem Projekt hinzu.
- Öffnen Sie die Quelldatei in Python.
- Verwenden Sie die Methode `post_workbook_save_as`, um den resultierenden Stream abzurufen.
System Anforderungen
- Python 2.7 oder neuer
- Python 3.10 oder neuer