C++ API för att exportera MD till PCL

Återge MD till PCL inom C++-applikationer utan att kräva någon tredjepartsapplikation

 

Aspose.Total for C++ filformatsautomatiseringsbibliotek tillåter C++-utvecklare att konvertera MD till PCL i två enkla steg. För det första kan du använda Aspose.PDF for C++ API för att konvertera MD-filformat till DOC. För det andra, genom att använda avancerad Word Document Processing API Aspose.Words for C++ , kan du exportera DOC till PCL.

C++ API för att rendera MD till PCL

  1. Öppna MD-filen med klassreferens Document
  2. Konvertera MD till DOC genom att använda medlemsfunktionen Save
  3. Ladda DOC-filen med hjälp av Document klassreferens för Aspose.Words API
  4. Spara dokumentet i PCL-format med hjälp av medlemsfunktionen Save

Konverteringskrav

Installera från kommandoraden som nuget install Aspose.Total.Cpp eller via Package Manager Console of Visual Studio med Install-Package Aspose.Total.Cpp.

Alternativt kan du hämta offline MSI-installationsprogrammet eller DLL-filer i en ZIP-fil från downloads .

// load MD file with an instance of Document class reference
auto doc = MakeObject<Document>(u"sourceFile.md");
// save MD as a DOC 
doc->Save(u"DocOutput.doc", SaveFormat::Doc); 
// load DOC with an instance of Document
System::SharedPtr<Document> wordDoc = System::MakeObject<Document>(u"DocOutput.doc");
// save document as Pcl
wordDoc->Save(u"output.Pcl");  

Ändra lösenord för MD-dokument via C++

I processen att rendera MD till PCL kan du öppna en lösenordsskyddad MD och även ändra dess lösenord. För att ändra lösenordet för en MD-fil måste du känna till ägarlösenordet för det dokumentet. Du kan ladda lösenordsskyddade PDF-dokument med Aspose.PDF for C++ genom att ange dess ägarlösenord och använda ChangePasswords-metoden för att ändra lösenordet.

// load an existing MD Document
auto doc = MakeObject<Document>(L"input.md", L"owner");
// change password of MD Document
doc->ChangePasswords(L"owner", L"newuser", L"newuser");
// save the document
doc->Save(L"output.Doc");

Begränsa PCL-filredigering via C++

Du kan också begränsa redigering av PCL-filer genom att använda Aspose.Words for C++ API. Ibland kan du behöva begränsa möjligheten att redigera ett dokument och endast tillåta vissa åtgärder med det. API låter dig styra hur du begränsar innehållet med hjälp av uppräkningsparametern ProtectionType . Följande kodexempel visar hur man begränsar redigering i ett dokument så att endast redigering i formulärfält är möjlig.

// load Doc with an instance of Document
auto doc = System::MakeObject<Document>("input.doc");
// document protection only works when document protection is turned and only editing in form fields is allowed.
doc->Protect(ProtectionType::AllowOnlyFormFields, u"password");
// save the protected document.
doc->Save(u"Protected.Pcl");  

Utforska MD konverteringsalternativ med C++

Konvertera MDs till DOCM (Microsoft Word 2007 Marco File)
Konvertera MDs till DOT (Microsoft Word Template Files)
Konvertera MDs till DOTM (Microsoft Word 2007+ Template File)
Konvertera MDs till DOTX (Microsoft Word Template File)
Konvertera MDs till FLATOPC (Microsoft Word 2003 WordprocessingML)
Konvertera MDs till GIF (Graphical Interchange Format)
Konvertera MDs till MHTML (Web Page Archive Format)
Konvertera MDs till ODT (OpenDocument Text File Format)
Konvertera MDs till OTT (OpenDocument Standard Format)
Konvertera MDs till PS (PostScript File)
Konvertera MDs till RTF (Rich Text Format)
Konvertera MDs till WORDML (Microsoft Word 2003 WordprocessingML)
Konvertera MDs till CSV (Comma Seperated Values)
Konvertera MDs till DIF (Data Interchange Format)
Konvertera MDs till EXCEL (Spreadsheet File Formats)
Konvertera MDs till FODS (OpenDocument Flat XML Spreadsheet)
Konvertera MDs till ODP (OpenDocument Presentation Format)
Konvertera MDs till ODS (OpenDocument Spreadsheet)
Konvertera MDs till OTP (OpenDocument Standard Format)
Konvertera MDs till POT (Microsoft PowerPoint Template Files)
Konvertera MDs till POTM (Microsoft PowerPoint Template File)
Konvertera MDs till POTX (Microsoft PowerPoint Template Presentation)
Konvertera MDs till PPS (PowerPoint Slide Show)
Konvertera MDs till PPSM (Macro-enabled Slide Show)
Konvertera MDs till PPSX (PowerPoint Slide Show)
Konvertera MDs till PPT (Microsoft PowerPoint 97-2003)
Konvertera MDs till PPTM (Macro-enabled Presentation File)
Konvertera MDs till SWF (Shockwave Flash Movie)
Konvertera MDs till SXC (StarOffice Calc Spreadsheet)
Konvertera MDs till TSV (Tab Seperated Values)
Konvertera MDs till TXT (Text Document)
Konvertera MDs till XLAM (Excel Macro-Enabled Add-In)
Konvertera MDs till XLSB (Excel Binary Workbook)
Konvertera MDs till XLSM (Macro-enabled Spreadsheet)
Konvertera MDs till XLT (Excel 97 - 2003 Template)
Konvertera MDs till XLTM (Excel Macro-Enabled Template)