Skip to main content
Reporting Using Aspose File Format API

Reporting Using Aspose File Format API

Aspose APIs:

Aspose is a file format API provider which provides .NET, Java, Android, Share-point, Reporting Services, and cloud-based APIs for document generation, conversion, and automation. It functions with documents produced with Microsoft Word, Excel, PowerPoint,Portable Document Format and Open Document, and also has APIs to handle bar-codes, optical character recognition, and email formats and protocols.

Aspose REST APIs allow users to integrate document processing and management tasks into their applications.

File Formats:

 Converting Pdf File to different file formats and vise versa.

File Formats API

 Aspose API References for .NET-Namespaces:

Aspose.Pdf : Aspose.Pdf,Aspose.Pdf.Devices,Aspose.pdf.DOM etc

Aspose.Words : Aspose.words, Aspose.words.drawing, Apsose.word.fields, Aspose.words.Lists etc

Aspose.Cells : for layout and font changes

Aspose.Slides: create a slides in aspose

Aspose.Email: supports email formatting

Aspose.Barcodes: supports bar-code reading and scanning

Aspose.Imaging: works for image process and convection from different types

Aspose.Tasks:support document tasks.

Aspose.OCR:Recognize the text in image and Converting image text to words

Aspose.Diagram:draw your own diagrams as continent

Aspose.Notes: maintains the details about your notes for future maintain.

Aspose.3D:Support 3D creation and display.

Examples:

An overview of the input and output capabilities of Aspose.Pdf for .NET.

Aspose.Pdf for .NET.

In Aspose, column names will be in XML document, and therefore for customization it is very easy for clients, According to their format they can convert these reports. Here I am going to explain how to convert an XML document file to .docx report.

How To Generate Data From XML to Word Document File?

XML format

<InvoiceData>
  <NotificationType>CustomerInvoiceViewFormData</NotificationType>
  <Title>Customer Invoice</Title>
  <Properties>
    <Property label="Project Name:" value="My first project" />
    <Property label="Project Number:" value="Proj001" />
    <Property label="Subject:" value="Subject of Customer Invoice" />
    <CustomerCode>Cust001</CustomerCode>
    <CustomerName>Technical Re-presenter Ltd</CustomerName>
    <Date>Jan-24-2017 </Date>
    <Subject>Subject of Customer Invoice</Subject>
<Status>Open</Status>
<InvoiceID>INV0001</InvoiceID>
<ProductDetails>
   <ItemID>ITM001</ItemID>
   <InvoiceID>INV0001</InvoiceID>
   <Product>CNC Compont</Product>
   <Quantity>2</Quantity>
   <Price>$500.00</Price>
       <TotalAmount>$1000.00</TotalAmount>
   </ProductDetails>
</InvoiceData>

Generate Data From XML to Word Document File

 

In this above example all fields with <InvoiceData> is table name and <Column names> values </column names end>.

We link this XML document to our Word document to display customized report.  In .docx file. we just use the formula, as shown below:

«NFSectionStart:CustomerInvoice»
Customer Name : <<CustomerName>>   //

Here right click and select Toggle code fields, looks like

{MERGEFIELD  CustomerName\* MERGEFORMAT }
«NFSectionEnd:CustomerInvoice»

In a similar manner, we can generate documents according to the client’s customized report formats.

Given below are the code format names to find the values in Aspose words using C#.net, code logic to bind the data to XLM files fields.

NFField

NFSectionStart

MERGEFIELD etc.

Shows the Invoice template for Customer.

Invoice Template

Advantages:

  1. Quickly And reliably, convert between several popular document formats.
  2. The fastest and most complete DOC format implementation you can find
  3. Aspose.Words provides exhaustive support OOXML,Flat OPC and also Word 2003 XML
  4. Comprehensive support of the RTF format to interact with a variety of applications
  5. Load and save HTML/XHTML/MHTML for greater interoperability.
  6. You can read the text from images using aspose.OCR from ocrEngine class.

Start ups, small scale and large organizations are using Aspose API’s example.  Microsoft, Apple and Newforma are using this extensively for document management with .net framework. Finally, it also works for cross platforms.

.NET And Java API Licensing

Aspose licenses are based on the number of developers and the number of locations where the components will be used.

 

 

Mallesh Vibhuti

Mallesh Vibhuti

Mallesh Y Vibhuti is a Senior Software Engineer with Trigent Software. With over six years experience he is skilled in languages such as C#, WinForms,SQL Server,MySQL,SSRS,ADO.Net and WCF. Mallesh enjoys adapting to new technologies really quickly.

Leave a Reply

Your email address will not be published. Required fields are marked *

nineteen − twelve =