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 6531563
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T09:53:35+00:00 2026-05-25T09:53:35+00:00

I ask a question here How to create simple XML in OmniXML and I

  • 0

I ask a question here How to create simple XML in OmniXML and I get an answer from Gavin Watkinson.

I create the unit:

interface

uses
 OmniXML, OmniXMLProperties;

type
 TRow = class(TGpXMLData)
 public
  constructor Create(Node: IXMLNode); override;

  property Id: integer index 0 read GetXMLPropInt write SetXMLPropInt;
  property Name: WideString index 1 read GetXMLPropWide write SetXMLPropWide;
  property Surname: WideString index 2 read GetXMLPropWide write SetXMLPropWide;
  property Time: WideString index 3 read GetXMLPropWide write SetXMLPropWide;
  property Old: WideString index 4 read GetXMLPropWide write SetXMLPropWide;
  property Subject: WideString index 5 read GetXMLPropWide write SetXMLPropWide;
end;

TRows = class(TGpXMLList)
protected
  function GetRow(Value: integer): TRow;
public
  constructor Create(ParentNode: IXMLNode); reintroduce;

  function Add: TRow; reintroduce;

  property Rows[Value: integer]: TRow read GetRow; default;
end;

TRootsXml = class(TGpXmlDocList)
private
  fRows: TRows;
public
  constructor Create; reintroduce;
  destructor Destroy; override;

  property Ver: WideString index 0 read GetXMLAttrPropWide write SetXMLAttrPropWide;
  property RootFile: WideString index 1 read GetXMLAttrPropWide write SetXMLAttrPropWide;

  property Rows: TRows read fRows;
end;

implementation

constructor TRow.Create(Node: IXMLNode);
begin
  inherited;

  InitChildNodes(['id', 'name', 'surname', 'time', 'old', 'subjects'], 
                 ['', '', '', '', '', '']);
end;

constructor TRows.Create(parentNode: IXMLNode);
begin
  inherited Create(parentNode, '', 'row', TRow);
end;

function TRows.Add: TRow;
begin
  Result := TRow(inherited Add);
end;

function TRows.GetRow(Value: Integer): TRow;
begin
  Result := TRow(inherited Items[Value]);
end;

constructor TRootsXml.Create;
var
  xmlPI: IXMLProcessingInstruction;
begin
  inherited Create('Root', '', '', nil);

  xmlPI := XMLDoc.CreateProcessingInstruction('xml', 'version="1.0" encoding="utf-8"');
  XMLDoc.InsertBefore(xmlPI, node);

  InitChildNodes(['ver', 'file'], ['', '']);

  fRows := TRows.Create(node);
end; 

destructor TRootsXml.Destroy;
begin
  fRows.free;

  inherited;
end;

When I try to TRootsXml.ver = 'sat123'; and try to compile I get this error. ‘Internal error E5912’ and not compiling…
But I can build without problem and run it.

So what is wrong and what is internal error E5912?

  • 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. Editorial Team
    Editorial Team
    2026-05-25T09:53:36+00:00Added an answer on May 25, 2026 at 9:53 am

    Internal errors are, well, internal errors in the compiler or linker. This time, it looks like the compiler. The number is merely an indication to the people who actually wrote the compiler. What it means is not documented and it is something that should actually never happen, in other words, it is a bug in the compiler. If it happens, you can only guess where or why it happens and try to modify your code until it disappears. That is not easy, and can be frustrating, but it is the only thing you can do.

    I assume it is related to the fact that the code uses indexed properties with getters and setters defined in an ancestor class. I guess you could write your own getters and setters and call the inherited getters with the given index. Try this:

      TRootsXml = class(TGpXmlDocList)
      private
        fRows: TRows;
        function GetVer: WideString;
        procedure SetVer(const Value: WideString);
        function GetRootFile ... etc.. 
      public
        constructor Create; reintroduce;
        destructor Destroy; override;
    
        property Ver: WideString read GetVer write SetVer;
        property RootFile: WideString read GetRootFile write SetRootFile;
        property Rows: TRows read fRows;
      end;
    
    function TRootsXml.GetVer: WideString;
    begin
      Result := GetXMLAttrPropWide(0);
    end;
    
    procedure TRootsXml.SetVer(const Value: WideString);
    begin
      SetXMLAttrPropWide(0, Value);
    end;
    
    // etc... similar code for GetRootFile and SetRootFile, but with index 1.
    

    Not sure if that works, as I don’t have Delphi 7 installed anymore, but please try it and report what happened.

    I guess the original code was meant to be used in a higher version. That does not explain the internal error (as I said, these are bugs in the compiler), but it explains why it doesn’t compile as expected, since I assume the code was tested, but apparently not in Delphi 7.

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

Sidebar

Related Questions

I was going to ask a question here about whether or not my design
maybe it's not so proper to ask this question here... anyway, I'm trying to
Sorry, this's my first time to ask a question here. So, I don't have
Just like Carl's question over here I would like to ask you (because I
I was just about to ask the same questions as the question aksed here....
There may be more than one way to ask this question, so here's a
I created a question on serverfault.com, and it was recommended that I ask here.
First of all, I apologise if the question I ask here is stupid, I
I read a lot of question and answer on TDD and unit testing on
I'm sorry to ask such a simple question with such a small amount of

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.