Modern JavaScript perpustakaan ngijini Node.js via .NET gawe kanggo nggabungaken DOC menyang siji JPG karo sawetara garis saka kode. Mesin konversi DOC nganalisa tata letak lan struktur DOC konten gabungan menyang JPG format.
Gunakake JavaScript kanggo ngowahi DOC dadi JPG kanthi keluwesan lan kacepetan maksimal. Jalanake demo online lan priksa JPG paling dhuwur ing browser. DOC Conversion API ndhukung akeh opsi migunani.
Kanggo ngowahi sawetara DOC menyang JPG mung nggunakake JavaScript sing nangani kabeh rincian tingkat rendah.
Ngonversi pirang-pirang DOC lan simpen asil minangka file siji JPG. Yen sampeyan ngembangake kode nggunakake JavaScript, iki bakal luwih gampang tinimbang sing katon. Deleng JavaScript sing ngulang dokumen lan ngowahi dadi JPG format:
npm install @aspose/words
Nyalin
const aw = require('@aspose/words');
var fileNames = [ "Input1.doc", "Input2.doc" ]
var output = new aw.Document()
// Mbusak kabeh content saka dokumen tujuan sadurunge nambah.
output.removeAllChildren()
fileNames.forEach(fileName => {
var input = new aw.Document(fileName);
// Tambahake dokumen sumber menyang pungkasan dokumen tujuan
output.appendDocument(input, aw.ImportFormatMode.KeepSourceFormatting);
});
for (var page = 0; page < output.pageCount; page++) {
var extractedPage = output.extractPages(page, 1);
extractedPage.save(`Output_${page + 1}.jpg`);
}
We host our Node.js via .Net packages in NPM repositories. Please follow the step-by-step instructions on how to install "Aspose.Words for Node.js via .NET" to your developer environment.
This package is compatible with Node.js 14.17.0 or higher.
Sampeyan bisa nggabungake DOC menyang akeh format file liyane: