On 10/9/08, Sergei Gorelkin <[EMAIL PROTECTED]> wrote:
>
> Bart wrote:
> >
> > Then how can I free those TDOMNodeList objects? I.o.w. how can I get
> > access to them?
> >
>
> You just put them into a variable and later call Free:
>
> var
>Nodes: TDOMNodeList;
> ...
> Nodes := MyNode.ChildNodes
Bart wrote:
>
> Then how can I free those TDOMNodeList objects? I.o.w. how can I get
> access to them?
>
You just put them into a variable and later call Free:
var
Nodes: TDOMNodeList;
...
Nodes := MyNode.ChildNodes;
writeln(Nodes[0].NodeName);
...
Nodes.Free
> I tried that, and it wordk li
>
> The memory leak is caused by using the ChildNodes property. Each time
> you use it, a new TDOMNodeList object is created, which must be
> eventually destroyed by calling Free. The FCL DOM implementation does
> not offer automatic memory management here, unlike other implementations.
Then how
Jesus Reyes wrote:
>
> By the way, and taking the fact that xml files are stored always in utf-8
> encoding it's surprising that for example XMLConfig doesn't have a way to set
> a value which is already utf-8 encoded. so, any change to add a methods that
> take utf-8 encoded strings as argumen
--- El mié 8-oct-08, Sergei Gorelkin <[EMAIL PROTECTED]> escribió:
> De:: Sergei Gorelkin <[EMAIL PROTECTED]>
> Asunto: Re: [Lazarus] XML and memory loss
> A: "General mailing list"
> Fecha: miércoles, 8 octubre, 2008, 10:49 am
> Bart wrote:
>
>
Bart wrote:
...
>
> This file is more or less as I excpected it to be (i would think it
> would include the encoding="utf-8").
Currently changing the encoding is not supported, and files are always
written in utf-8 encoding. According to the XML specs, files without
encoding label are read as
Hi all,
I am totaly nes to this (XML), so I suppose i do something wrong.
I took the example from the Wiki XML Tutorial, and the simplified it.
(I use Lazarus svn revision 16824, with fpc 2.2.0 on Window ME)
Here's my code to write an XML file:
procedure TForm1.Button1Click(Sender: TObject);
va
Ok BIG thanks to all :))
yup Gustavo is right, with 2 elements the formating is ok.
I'm sorry i haven't tried with 2 items, my knowledge with the use of xml is
limited :x a bit better now haha.
Thanks again a lot to all of you it's very cool !
Graeme Geldenhuys wrote:
> On Tue, Oct 7, 2008 at
On Tue, Oct 7, 2008 at 10:23 PM, Michael Van Canneyt
<[EMAIL PROTECTED]> wrote:
>> I know whitespace is irrelevant in XML, but I always thought there was
>> a "pretty format" option somewhere. FPCUnit's xml output is formatted
>> pretty. So is Lazarus's .xml config files. What do they use then?
>
3 Load and Save) define such an option, but it
isn't implemented yet. Both FCL and Lazarus XML writers try to
pretty-format their output, but it isn't perfect. FCL writer used to
write 'leaf' nodes (i.e. nodes without children) without indenting -
this is what you see in the o
2008/10/7 Graeme Geldenhuys <[EMAIL PROTECTED]>:
> On Tue, Oct 7, 2008 at 9:28 PM, Michael Van Canneyt
> <[EMAIL PROTECTED]> wrote:
>>
>> You cannot control the formatting. This is part of the XML specs, and is
>> normal.
>> Whitespace is irrelevant in XML, except for some special cases.
>
> I kno
On Tue, 7 Oct 2008, Graeme Geldenhuys wrote:
> On Tue, Oct 7, 2008 at 9:28 PM, Michael Van Canneyt
> <[EMAIL PROTECTED]> wrote:
> >
> > You cannot control the formatting. This is part of the XML specs, and is
> > normal.
> > Whitespace is irrelevant in XML, except for some special cases.
>
> I
On Tue, Oct 7, 2008 at 9:28 PM, Michael Van Canneyt
<[EMAIL PROTECTED]> wrote:
>
> You cannot control the formatting. This is part of the XML specs, and is
> normal.
> Whitespace is irrelevant in XML, except for some special cases.
I know whitespace is irrelevant in XML, but I always thought ther
On Tue, Oct 7, 2008 at 6:52 PM, <[EMAIL PROTECTED]> wrote:
>
> the only problem is that the formating is not good :/
> here the result:
>
>
>
>
> what i missed to have an xml file like that ?
>
>
>
>
>
>
Ah, that's the "compact" format... I thought there was a property to
toggle that, bu
On Tue, 7 Oct 2008, [EMAIL PROTECTED] wrote:
> i have a light problem with xml.
> here my code:
>
> {.create the document}
> CFWxmlFile:=TXMLDocument.Create;
> {.create the root node of the configuration file}
> CFWxmlRoot:=CFWxmlFile.CreateElement('configfile');
> CFWxmlFil
i have a light problem with xml,
here my code:
{.create the document}
CFWxmlFile:=TXMLDocument.Create;
{.create the root node of the configuration file}
CFWxmlRoot:=CFWxmlFile.CreateElement('configfile');
CFWxmlFile.AppendChild(CFWxmlRoot);
{.create the config item "locale"
i have a light problem with xml.
here my code:
{.create the document}
CFWxmlFile:=TXMLDocument.Create;
{.create the root node of the configuration file}
CFWxmlRoot:=CFWxmlFile.CreateElement('configfile');
CFWxmlFile.AppendChild(CFWxmlRoot);
{.create the config item "locale
I begin to implement xml read/write on my game for all the data and config
file,
and the complete doc i found is here :
http://wiki.lazarus.freepascal.org/XML_Tutorial
wiki is your friend :)
Graeme Geldenhuys wrote:
> On Sun, Oct 5, 2008 at 8:50 PM, eak <[EMAIL PROTECTED]> wrote:
>> how to use
On Sun, Oct 5, 2008 at 8:50 PM, eak <[EMAIL PROTECTED]> wrote:
>
> how to use xml with lazarus , i don't find document or i found it
> complex document and i don't understand.
The question is rather: "What do you want to do with XML?" Save
application settings, export/import data etc...
Regard
Hi,
how to use xml with lazarus , i don't find document or i found it
complex document and i don't understand.
Thanks.
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
On Sat, 30 Aug 2008 11:04:11 +0200
zeljko <[EMAIL PROTECTED]> wrote:
> why is this so ? new bug ?
A broken xml file.
> TCodeHelpManager.GetFPDocFilenameForSource TLazPackage
> TApplication.HandleException In (line 1501 pos 7): Expected
> ">", found "<"
> Stack trace:
> $0828B532 TXMLREA
A broken XML file ?
Ido
On Sat, Aug 30, 2008 at 12:04 PM, zeljko <[EMAIL PROTECTED]> wrote:
> why is this so ? new bug ?
>
> TCodeHelpManager.GetFPDocFilenameForSource TLazPackage
> TApplication.HandleException In (line 1501 pos 7): Expected ">",
> found "<"
> Stack trace:
> $0828B532 TXMLRE
why is this so ? new bug ?
TCodeHelpManager.GetFPDocFilenameForSource TLazPackage
TApplication.HandleException In (line 1501 pos 7): Expected ">",
found "<"
Stack trace:
$0828B532 TXMLREADER__RAISEEXC, line 277 of laz_xmlread.pas
$0828B755 RAISESTRINGNOTFOUND, line 307 of laz_xmlread.
23 matches
Mail list logo