Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 70109
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T19:40:45+00:00 2026-05-10T19:40:45+00:00

I’m planning to add XML support to application, but I’m not familiar with XML

  • 0

I’m planning to add XML support to application, but I’m not familiar with XML programming in Delphi. Basically I need to create objects based on XML nodes and generate XML file based on objects.

Which XML component library I should use? Are there any good tutorials for XML with Delphi?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T19:40:46+00:00Added an answer on May 10, 2026 at 7:40 pm

    You can start by looking at Delphi’s TXMLDocument component. This will provide you with the basics of working with XML/DOM. It’s simple and can be added by dropping it onto your Form. It has LoadFromFile and SaveToFile methods and is easily navigated.

    However, at some point you will exhaust TXMLDocument’s features, especially if you want to work with things like XPath.

    I suggest you look at IXMLDOMDocument2 which is part of MSXML2_TLB, e.g.

      XML := CreateOleObject('MSXML2.DOMDocument.3.0') as IXMLDOMDocument2;   XML.async := false;   XML.SetProperty('SelectionLanguage','XPath'); 

    You will need to add msxmldom, xmldom, XMLIntf, XMLDoc & MSXML2_TLB to your uses section.

    There are a few component libraries out there but I would suggest writing your own helper class or functions. Here’s an example of one we wrote and use:

    function XMLCreateRoot(var xml: IXMLDOMDocument2; RootName: string; xsl: string = ''; encoding: string = 'ISO-8859-1'; language: string = 'XPath'): IXMLDOMNode; var   NewPI:   IXMLDOMProcessingInstruction; begin    if language<>'' then      xml.SetProperty('SelectionLanguage','XPath');    if encoding<>'' then begin      NewPI:=xml.createProcessingInstruction('xml', 'version='1.0' encoding=''+encoding+''');      xml.appendChild(NewPI);   end;    if xsl<>'' then begin      NewPI:=xml.createProcessingInstruction('xml-stylesheet','type='text/xsl' href=''+xsl+''');      xml.appendChild(NewPI)   end;    xml.async := false;   xml.documentElement:=xml.createElement(RootName);   Result:=xml.documentElement; end; 

    Take it from there.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
Seemingly simple, but I cannot find anything relevant on the web. What is the
I want to count how many characters a certain string has in PHP, but
I have a French site that I want to parse, but am running into
Does anyone know how can I replace this 2 symbol below from the string
this is what i have right now Drawing an RSS feed into the php,
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.