[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: [xsl] Accessing file properties
Subject: Re: [xsl] Accessing file properties
From: "Manfred Staudinger" <manfred.staudinger@xxxxxxxxx>
Date: Sun, 27 Jan 2008 13:05:45 +0100
|
> I wish to replace "WORD_DOC_NAME" with the file name
you can use document-uri(), e.g.
tokenize(document-uri(/), '/')[last()]
if that is what you want.
Regards, Manfred
On 27/01/2008, Sean Tiley <sean.tiley@xxxxxxxxx> wrote:
> Hi Alice,
> Yes, I want to output the document name in my resulting xml file which
> looks like the following
>
> <testresults>
> <file name="WORD_DOC_NAME">
> <testruns>
> <testrun>
> <test case="TC-01" result="FAIL" date="2008-01-25" bugid="123"/>
> <test case="TC-02" result="FAIL" date="2008-01-25" bugid="456"/>
> <test case="TC-03" result="FAIL" date="2008-01-25" bugid="789"/>
> <test case="TC-04" result="PASS" date="2008-01-25"/>
> </testrun>
> <testrun>
> <test case="TC-01" result="PASS" date="2008-01-26"/>
> <test case="TC-02" result="PASS" date="2008-01-26"/>
> <test case="TC-03" result="FAIL" date="2008-01-26" bugid="790"/>
> <test case="TC-04" result="PASS" date="2008-01-26"/>
> <test case="TC-05" result="PASS" date="2008-01-26"/>
> <test case="TC-06" result="FAIL" date="2008-01-26" bugid="791"/>
> </testrun>
> </testruns>
> </file>
> <file/>
> ...
> </testresults>
>
>
> I wish to replace "WORD_DOC_NAME" with the file name
>
> Thanks
> Sean
>
>
> On Jan 26, 2008 9:43 PM, Wei, Alice J. <ajwei@xxxxxxxxxxx> wrote:
> > Hi, Sean:
> >
> > Are you saying that you would like to display the attributes in your data? Or, are you referring to something else?
> >
> > Please display a portion of the data of what you would like to output.
> >
> > Thanks.
> >
> > Alice
> >
> > ======================================================
> > Alice Wei
> > MIS 2008
> > School of Library and Information Science
> > Indiana University Bloomington
> > ajwei@xxxxxxxxxxx
> >
> >
> >
> > -----Original Message-----
> > From: Sean Tiley [mailto:sean.tiley@xxxxxxxxx]
> > Sent: Saturday, January 26, 2008 9:36 PM
> > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> > Subject: [xsl] Accessing file properties
> >
> > Hi there,
> > I am using XSLT 2.0 and what I am doing is processing word files,
> > (saved in xml format).
> >
> > The word files are documents that describe a piece of software
> > functionality to be tested by a qa analyst along with the test cases.
> > The results of the test cases are recorded in the table alongside the
> > test cases.
> >
> > I can successfully extract the test case result information (Test case
> > ID, Date executed, PASS/FAIL, Bug ID etc) from the table within the
> > word doc and format it how I need.
> >
> > I am wondering if during the transformation I have access to the word
> > document properties such as name, size, modification date etc?
> >
> >
> > Thanks
> > --
> > Sean Tiley
> > sean.tiley@xxxxxxxxx
> >
> >
>
>
>
> --
> Sean Tiley
> sean.tiley@xxxxxxxxx
|