For an effective way of communication with the audience, you may need to convert Word document to PowerPoint presentations. PowerPoint presentations help users to refine their content with greater visual impact. So, this article covers how to convert Word Document to PowerPoint Presentation using Ruby.
- APIs for Word to PowerPoint Conversion
- Convert DOCX to PPTX or PPT in Ruby
- Word to PPTX Conversion with Advance Options
APIs for Word to PowerPoint Conversion
In order to convert a Word document to PowerPoint presentation, we’ll use GroupDocs.Conversion Cloud SDK for Ruby. The GroupDocs.Conversion document processing API for Ruby has been designed to help you get started with our document conversion Cloud REST API. It helps you to convert and manipulate your documents to a variety of supported file formats in your preferred language. It is completely independent of an operating system, database system and development language. You can convert more than 50 types of documents and images with this conversion API, including MS Office and OpenDocument file formats, PDF, HTML, CAD, raster images etc.
GroupDocs.Conversion Cloud SDK for Ruby is open source and has an MIT license. You can download it, use it, and even customize it according to your requirements. The Ruby SDK is available as a gem groupdocs_conversion_cloud at rubygems. You can install GroupDocs.Conversion Cloud API to convert word doc to powerpoint in Ruby application using this gem with below mentioned command in the rails console:
gem install groupdocs_conversion_cloud
Now, you need to add Client Id and Client Secret before making any requests to GroupDocs Conversion Cloud API. You can get client credentials by creating an application on the Groupdocs dashboard. Once you have Client Id and a Client Secret, add below ruby code snippet in your application:
Convert DOCX to PPTX or PPT in Ruby
The following are the steps to convert Word Document to PowerPoint Presentation programmatically using Ruby.
- First of all, create an instance of the ConvertApi.
- Next, create an instance of the ConvertSettings.
- Then, set the input DOCX file path.
- Now provide format for the output file as the “pptx”.
- Create an instance of the DocxLoadOptions.
- Set hide_word_tracked_changes, default_font and load_options values.
- Create an instance of the PptxConvertOptions.
- Set from_page, pages_count, zoom and convert_options values
- Now, provide the output directory path as “conversion”.
- Next, create ConvertDocumentRequest instance with provided settings.
- Finally, call convert_document() method with settings object as an argument.
The following code snippet shows how to turn a word document into a powerpoint in Ruby using REST API.
Word to PPTX Conversion with Advance Options
The following are the steps to convert Word DOCX into PPTX with advance options using Ruby. It has been used in the convert to Slides format of GroupDocs.Conversion Cloud REST API.
- First, create an instance of the ConvertApi.
- Create an instance of the ConvertSettings.
- Now, create PresentationConvertOptions
- Set from_page, pages_count, convert_options and output_path as “conversion”
- Finally, call convert_document() method with ConvertDocumentRequest instance and settings object as an argument.
Get a Free API License
You can use the APIs without evaluation limitations by requesting a temporary license.
Try Online Converter For Free
You can also try the online PowerPoint to Word converter, which is based on the above mentioned APIs.
Conclusion
In this article, we have learned how to convert Word DOCX to PowerPoint PPT or PPTX using ruby. We also how to convert word document to powerpoint presentation using Ruby. You can simply install the APIs and integrate the provided code in your ruby applications. In addition, We also provide an API Reference section and you can consult the documentation to explore other features of the APIs.
Ask a question
If you have any queries about DOCX to PPTX converter, please feel free to ask us via our Forum.
See Also
We recommend following related link of supported document conversions: