Re: [xml] XPATH Numbers don't work



On Wed, Nov 28, 2001 at 01:38:05PM +0100, Uwe Fechner wrote:
Hello,

I am using libxml2.dll version 2.4.10 for windows. (from Igor).
I use the delphi-header-translations from
http://sourceforge.net/projects/libxml2-pas.
(Together with delphi 6.0 fixpack 1).

  heh I didn't know this existed :-)

I have a problem using xpath.

The results are ok if they have the type nodeset.

Results of type number are always zero, strings are always empty.
[...]
    XPATH_NUMBER:
      begin
        number:=res.floatval;
        temp:='Number: '+floattostr(number);
      end;
    XPATH_STRING:
      begin
        temp:='String: '+res.stringval;
      end;
    else
      begin
        temp:='???';
      end;

  Hum, this looks sensible but the best is probably to ask the author
of the pascal wrapper.
  I remember for example (old memory from the TurboPascal at the end of
the 80's) that Pascal strings had a different in-memory representation
from C ones. For the floats, it's strange it should be mostly architecture
dependant, not language dependant...

Daniel

-- 
Daniel Veillard      | Red Hat Network https://rhn.redhat.com/
veillard redhat com  | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]