Introducing the “Welcome to Xojo” Bundle!

New to Xojo and looking for guidance? We've put together a terrific bundle to welcome you! Xojo Bundle

This bundle includes six back issues of the magazine -- all of year 21 in printed book and digital formats -- plus a one-year subscription (beginning with 22.1) so you'll be learning all about Xojo for the next year. It's the perfect way to get started programming with Xojo. And you save as much as $35 over the non-bundle price!

This offer is only available for a limited time as supplies are limited, so hurry today and order this special bundle before the offer goes away!

Article Preview

Buy Now

Issue 15.5 ('Touch Bar')
Instant purchase and download via GumRoad!


Sharing Data for Health, Part 3

Exporting health data to XML

Issue: 15.5 (September/October 2017)
Author: JC Cruz
Author Bio: JC is a freelance writer based in British Columbia. He contributes regularly to MacTech Magazine and Dr Dobb's Journal. Away from the writing pile, JC spends quality time with his nephew, as a proper uncle should.
Article Description: No description available.
Article Length (in bytes): 44,427
Starting Page Number: 48
Article Number: 15506
Resource File(s):

Download Icon project15506.zip Updated: 2017-09-05 00:14:55

Related Link(s): None

Excerpt of article text...

I gave FooHealth the ability to export its health data, and I gave it the ability to import data as well. Now I face the challenge of adding XML support to both features. Today's article on data shall show how I export data to XML.

First, I extoll the benefits of supporting XML. I shall introduce the XML document object and explain the challenges in generating and processing such an object. I shall describe the key XML classes defined by Xojo. And I shall show how I assemble the document, then save it to an external file.

Readers need a working knowledge of Xojo, XML, and object-oriented design. An updated version of the FooHealth demo project (mk10.2) is available from the magazine's website.

The Beauty of XML

Since its first public appearance in 2008, XML (eXtensible Markup Language) has become the format of choice for many files, for many network protocols. It has strong support for the Unicode character set, it is portable, and it works well with complex data structures.

XML is similar to HTML in many ways. Both use markup tags to divide and organize their content. Both are network-friendly. And both require that user data be rendered first into text.

...End of Excerpt. Please purchase the magazine to read the full article.