PRODUCT_NAME_ALT

Merge XML with DOTM for Free in swift

Use a free app or Swift SDK to merge XML and DOTM, along with several popular formats from Microsoft® MS Excel.

Swift Code for Merging XML Files into DOTM: A Complete Guide

// Merge XML to HTML
// Code will available soon
%!(EXTRA string=XML, string=HTML)
// Merge HTML to DOTM
let requestDocument = InputStream(url: URL(string: localFile))!;
let requestDocumentListDocumentEntries0FileReferenceStream = InputStream(url: self.getLocalTestDataFolder().appendingPathComponent(localFile, isDirectory: false))!;
let requestDocumentListDocumentEntries0FileReference = FileReference(localFileContent: requestDocumentListDocumentEntries0FileReferenceStream);
let requestDocumentListDocumentEntries0 = DocumentEntry()
.setImportFormatMode(importFormatMode: "KeepSourceFormatting")
.setFileReference(fileReference: requestDocumentListDocumentEntries0FileReference);
let requestDocumentListDocumentEntries = [
requestDocumentListDocumentEntries0 as! DocumentEntry
];
let requestDocumentList = DocumentEntryList()
.setDocumentEntries(documentEntries: requestDocumentListDocumentEntries);
let appendRequest = AppendDocumentOnlineRequest(document: requestDocument, documentList: requestDocumentList);
_ = try api.appendDocumentOnline(request: appendRequest);
%!(EXTRA string=HTML, string=DOTM)

How to Merge XML with DOTM in Cloud Apps

  1. Initialize WordsApi with Client Id, Client Secret, Base URL & API version
  2. Set requestDocument assign the local XML file name
  3. Set requestDocumentListDocumentEntriesFileReference and assign local DOTM file name
  4. Set requestDocumentListDocumentEntries and set file_reference, import_format_mode parameters
  5. Create DocumentEntryList instance and assing requestDocumentListDocumentEntries to document_entries parameter
  6. Call AppendDocumentOnlineRequest to merge XML file with DOTM document requestDocument and requestDocumentList
  7. Call WordsApi appendDocumentOnline with parameters

Get Started with Aspose.Total REST APIs

  1. Create an account at Dashboard to get free API quota & authorization details
  2. Get Aspose.Words and Aspose.Cells Cloud SDKs for Swift source code from Aspose.Words GitHub and Aspose.Cells GitHub repos to compile/use the SDK yourself or head to the Releases for alternative download options.
  3. Also have a look at Swagger-based API Reference for Aspose.Words and Aspose.Cells to know more about the REST API.

How to Merge MS Excel Spreadsheet(XML) and DOTM Files

Aspose.Cells Cloud provides efficient methods to merge multiple documents into a single file while preserving formatting.

Steps for Merging Documents:

  1. Create a MergeDocumentRequest Object to specify the source documents to be merged.
  2. Call the AppendDocument Method of the Aspose.Cells API class instance to merge one document into another.
  3. Use SaveOptions to define the output format (DOCX, PDF, etc.).
  4. Send API Request to combine documents into a single merged output.

How to Combine MS Excel and XML with Other Formats Online

Boost your document management efficiency by merging XML files with other formats using the robust Aspose.Cells API. Seamlessly integrate your merged documents with other Aspose.Total APIs such as Aspose.Words, Aspose.PDF, Aspose.Email, Aspose.Slides, Aspose.Diagram, Aspose.Tasks, Aspose.3D, Aspose.HTML. This all-in-one solution allows you to combine files into a single document across various formats.

For a full list of supported formats and merging features, visit the Aspose.Total Cloud page.

FAQ

  • What is XML Format?
    XML stands for Extensible Markup Language that is similar to HTML but different in using tags for defining objects. The whole idea behind creation of XML file format was to store and transport data without being dependent on software or hardware tools. Its popularity is due to it being both human as well as machine readable. This enables it to create common data protocols in the form of objects to be stored and shared over network such as World Wide Web (WWW). The “X” in XML is for extensible which implies that the language can be extended to any number of symbols as per user requirements. It is for these features that many standard file formats make use of it such as Microsoft Open XML, LibreOffice OpenDocument, XHTML and SVG.
  • I can not find the SDK for my favorite language. What should I do?
    Aspose.Total Cloud is also available as a Docker Container. Try using it with cURL in case your required SDK is not available yet.
  • Where can I see the release notes for Aspose.Total Cloud API?
    Complete release notes can be reviewed at Aspose.Total Cloud Documentation.
  • What file formats are supported by Aspose.Total Cloud API?
    Aspose.Total Cloud can merge file formats from any product family to any other product family to PDF, DOCX, XPS, image(TIFF, JPEG, PNG BMP), MD and more. Checkout the complete list of supported file formats.
  • Is it safe to merge XML with DOTM in the Cloud?
    Of course! Aspose Cloud uses Amazon EC2 cloud servers that guarantee the security and resilience of the service. Please read more about Aspose's Security Practices.
  • What is DOTM Format?
    A file with DOTM extension represents template file created with Microsoft Word 2007 or higher. It is similar to the popular DOCX file format other than it retains the user defined settings for reuse in case of creating new documents. Such documents are more often used in offices where a standard template file is generated with settings like page information, margins, default layout and macros, and is used to create new documents from it when required. DOTM files, however, save macros, that are a series of commands in the form of recorded actions for automatic completion of a task. This helps save time in carrying out actions that are repeated in completion of a task.
  • How can I get started with Aspose.Total REST APIs?
    Quickstart not only guides through the initialization of Aspose.Total Cloud API, it also helps in installing the required libraries.