June 27, 200619 yr Hi, I am trying to import a file using an xslt, however I can't quite figure out how to reach a certain node. Can someone just nudge me in the right direction ? I am trying to learn so don't spoil me too much. Thnx. --- What I've got A FM8-file with 3 fields : invoicenr, debtornr, amount What I want to get from the xml file is the values between the values-tags. I do get them now, but only form the first tag . How do I reach the others ? I got this xml-file : <?xml version="1.0" encoding="Windows-1252" standalone="yes" ?> 2006-06-20T12:33:13 ACCOUNTVIEW 0700A 25RA 232190 sub_nr 25RA inv_nr 232190 item_bal 4880 etc etc. my xslt so far ... <?xml version='1.0' encoding='UTF-8' ?> 0 Edited June 27, 200619 yr by Guest
June 27, 200619 yr First, I can't imagine how you could get anything out of the above xml; you've copied it incorrectly here. It is not valid. Its root element does not have a closing tag at the end, which is required for xml. Two other tags are also missing their closing tags. You need: You don't need 3 VALUE lines; you only need 1. The " automatically gets however many child elements there are within FIELD, in order. You are assuming that they always have 3, and that they are in the same order. If you need to check them for either which they are or their order, it is possible. But perhaps you don't need to, and you said not to spoil you -] Also, you don't really need the "./" in front of the elements. It is implied, i.e., "FIELD" is the same as "./FIELD", in this use anyway.
June 27, 200619 yr Author Thnx for the reply. The closing tags are enclosed in the etc. etc. part. The xml is valid. I figured I needed a different approach, what I can't find out is to reach the other value tags. This xsl only gives me the same tag 3times; no other data is received.
June 30, 200619 yr Author Thanks a lot. That was easier then expected, but learned quite a bit in the process.
Create an account or sign in to comment