How to Get Macro Info from a DOCX File in Java

// Import classes:
//import com.cloudmersive.client.invoker.ApiClient;
//import com.cloudmersive.client.invoker.ApiException;
//import com.cloudmersive.client.invoker.Configuration;
//import com.cloudmersive.client.invoker.auth.*;
//import com.cloudmersive.client.EditDocumentApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();// Configure API key authorization: Apikey
ApiKeyAuth Apikey = (ApiKeyAuth) defaultClient.getAuthentication("Apikey");
Apikey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
EditDocumentApi apiInstance = new EditDocumentApi();
File inputFile = new File("/path/to/inputfile"); // File | Input file to perform the operation on.
try {
GetMacrosResponse result = apiInstance.editDocumentDocxGetMacroInformation(inputFile);
} catch (ApiException e) {
System.err.println("Exception when calling EditDocumentApi#editDocumentDocxGetMacroInformation");




There’s an API for that. Cloudmersive is a leader in Highly Scalable Cloud APIs.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Software Engineering with a Disability

Web hosting is of mainly 3 types:

Food Delivery App Development — Build Food Delivery App Clone

Clone Food Delivery App Development

How to Write a Sophisticated SPA: TodoMVC using C#

Convert a Price from USD to EUR in Python

How to Build Your Own Cool Weather Widget Using Python with Tkinter and Pyinstaller

Styling a Form using HTML5 and CSS

90s CSS

Flux Node Setup with VMWare Workstation 16 Pro

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store


There’s an API for that. Cloudmersive is a leader in Highly Scalable Cloud APIs.

More from Medium

Image Processing API: How to Crop an Image to a Rectangular Area using Java

Java Server Pages(JSP)

Java Apache httpclient authentication for IBM FHIR

Send mail in java