Crazy Beleg offers the possibility to import customer and artile data. It is also possible to export documents, created in the app, to process them further in other programs. The exchange format for both import and export is an XML file.
The simplest form of data exchange is to export the data from an Microsoft Excel® file. Unfortunately, Microsoft Excel® does not provide a direct way to save a table as a pure XML file. The necessary steps are summarized in this wiki. All screenshots comes from Microsoft Office® 365. The individual points may slightly differ in different versions, but the general procedure is the following:
itemUnit: Sales unit of the article to which the price is based
* To import the customer data, please use the following attributes:
customerID: Unique customer number. This number is also output in the documents in order to establish a clear reference to your customer master. This number can not be changed in the app.
customerName: Name of the customer
customerStreet: Street of customer's address
customerZipCode: ZIP-Code of customer's address
customerCity: City of customer's address
customerPhone: Phone number (only for information)
customerDiscount: customer's discount (currently not used)
* After assigning the XML elements to the values in the table your workbook should look something like this:
* To export the data from Microsoft Excel, select the "Developer" menu and select "Export"
* If you have only one scheme in your workbook, this will be used without an upcomming dialog. In case you have two or more schemas, choose the import scheme and click "OK".
* Save your file in your Dropbox folder "Apps/CrazyDocument" or an other folder and click "Export". If you did not choose the Dropbox folder, copy the file in the folder "Apps/CrazyDocument" of your Dropbox.
* The name of the file for your items must be "items.xml" and for customers "customers.xml". Otherwise, the data can not be found.
* Now you should see a new file in your Dropbox
* Crazy Beleg has an option for the automatic import of master data. If you enable this option in the app, each time the app is activated, it checks to see if new customer or article data exists in your dropbox. You only need to copy a new file to the directory. The next time you launch the app or activate the current app from the background, your new data will be imported.
During the import the app is checking whether there is already a customer or article number. If yes, the master data are accepted without losing the reference in the documents. If a customer or item number does not yet exist, it is created.
Import of master data
Open the Crazy Document app on your iDevice. Customers are to be imported as an example.
* Select the "Customers" area and tap the Action button (at the top right)
* If the data can be processed and the structure of the data in the XML file is identical to that of the schema, an appropriate message is displayed and the data is displayed in the background.
The articles can also be imported analogously to the import of the customer data. Just select the Action button in the article display.
Export documents from the app
You have entered a document completely and want to close it now. To this purpose, the app offers several possibilities which you can reach via the action button in a displayed document:
* Save a document without additional action
* Print a document and export XML and PDF to Dropbox
* Print document / PDF only
* Export a document only
Save a document without additional action
This action saves only the current document. No data is printed or exported to the Dropbox. Save this action for later editing.
Print a document and export XML and PDF to Dropbox
This action will give you a preview of how your printed document will look like. The document is automatically saved.
To complete a document, tap the printer button at the top right. A print dialog is displayed in which you can select the correct output channel for you. On the one hand, this can be an AirPrint-enabled printer that is connected to your device or another app that takes the printout for you. It can also be apps from printer manufacturers, which offer the possibility to receive a document to be printed over the document exchange.
Select an available item from the list. If the app is able to transfer the document or print to an AirPrint printer, the document is marked as processed and an XML as well as an PDF file are automatically saved in your Dropbox.
Print document / PDF only
This action automatically saves the document and displays a preview. From here you can print the document as described above or save it as a PDF in your Dropbox. The data is not exported as an XML file. This action is used to print a document again without changing the data.
Export a document only
This action automatically saves the document and saves a new XML file in the Dropbox. There is no printout or export of the PDF file.
Structure of the XML file of a document
You can open the XML saved in the export with Microsoft Excel with the XML schema for downloaded documents (schemaDocument.xml). If you have installed the XML schema as described above, you can now double-click on the XML file in your Dropbox "Apps/CrazyDocument" directory and get the contents of your document.
The structure has the following meaning:
document: Unique identification of a document (Only once per document)
documentID: Document ID
createdAt: Creation date of the document
documentCustomerID: Unique customer number from customer base
documentNet: Net total of the document
documentTax: Amount of full VAT of the document
documentTaxReuduced: Amount of reduced VAT of the document
documentTotal: Total of the document (including all VAT amounts)
documentPaymentDays: Payment term in days
documentPaymentCashDiscount: Discount rate of the payment destination in percent
documentPosition: Identification of a position in the document (can occur several times)
positionID: Position ID of an item in the document
positionQuantity: Quantity of the item in the position
positionDiscount: Discount of the item in the position
positionTotal: Price of the position considering quantity and discount
positionItemID: Unique article number from the article master
In addition, you can use the Settings -> Section Import- and Export Options -> Export Master Data to specify whether you want to export the master data of the customer and the items. By default this option is disabled. The corresponding tags can be found in the description of the customers or articles.
Customize the XML structure to your own requirements
For the import of the data, a fixed structure and a clear identification is required to be successfully processed by the app. Not always these unique names (tags) fit your needs. For this reason the app provides a possibility to map the tags to your requirements. You can find it in Settings -> Section Import and Export Options -> XML mapping costomization. Here you can change all tags for the customer, item and document data.
The mapping for the document is shown here in the example. You can enter the tags to be used in the XML file. The short description can be found in the description of the structure. Please note that the tags are Case Sensitive!