Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save aspose-com-gists/50202f13b147b72b23d1b60d67e661da to your computer and use it in GitHub Desktop.
Save aspose-com-gists/50202f13b147b72b23d1b60d67e661da to your computer and use it in GitHub Desktop.
Convert RTF Documents to PDF using C++
Convert RTF Documents to PDF using C++
// Create an instance of Document class and load the RTF file
System::SharedPtr<Aspose::Words::Document> document = System::MakeObject<Aspose::Words::Document>(u"SourceDirectory\\Test File (rtf).rtf");
// Output file path
System::String outputPath = u"OutputDirectory\\TextFileOut.pdf";
// Save RTF as PDF
document->Save(outputPath, Aspose::Words::SaveFormat::Pdf);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment