Problem using xpath_eval in transform scenario output tab
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 72
- Joined: Thu Mar 26, 2015 4:57 pm
Problem using xpath_eval in transform scenario output tab
Post by steve.cuzner »
Hi,
I've got an ant transform scenario that generates a report about the current project files. It runs fine, but I want to open the report when it's complete, so I put this in the Output tab Open field:
If I remove the first concat argement,'${pd}\', it works fine, but the file won't open because it's trying to open relative to my current file which is in a sub-folder.
I've got an ant transform scenario that generates a report about the current project files. It runs fine, but I want to open the report when it's complete, so I put this in the Output tab Open field:
Code: Select all
${xpath_eval(concat('${pd}\', replace('${pn}', '_project', ''), '_report.xml'))}
-
- Posts: 72
- Joined: Thu Mar 26, 2015 4:57 pm
Re: Problem using xpath_eval in transform scenario output tab
Post by steve.cuzner »
I should add that with ${pd}\ no document is opened and no error is presented. If I remove it I get a cannot open file error.
-
- Posts: 72
- Joined: Thu Mar 26, 2015 4:57 pm
Re: Problem using xpath_eval in transform scenario output tab
Post by steve.cuzner »
Using a simplified test, it appears that the $pd variable isn't being expanded or is causing some error. Given the following code:
which doesn't resolve to an actual file, I get no error message.
Changing only the internal variable,
which still resolves to a file that doesn't exist, I do get a file not found error.
Code: Select all
${xpath_eval(concat('${pd}', '\foo.xml'))}
Changing only the internal variable,
Code: Select all
${xpath_eval(concat('${pn}', '\foo.xml'))}
Re: Problem using xpath_eval in transform scenario output tab
Hi Steve,
I found one way for you to debug this on your side.
If you edit the ANT transformation scenario, in the "Parameters" tab you can add a new parameter called for example "abc" and having as value:
${xpath_eval(concat('${pd}\', replace('${pn}', '_project', ''), '_report.xml'))}
Then run the transformation. Oxygen should expand the value and then show in the console view which pops up in the command line something like:
"-Dabc=D:\myProjects\samples\sample_report.xml"
So from what I tested on my side the ${pd} seemed to be properly expanded.
Regards,
Radu
I found one way for you to debug this on your side.
If you edit the ANT transformation scenario, in the "Parameters" tab you can add a new parameter called for example "abc" and having as value:
${xpath_eval(concat('${pd}\', replace('${pn}', '_project', ''), '_report.xml'))}
Then run the transformation. Oxygen should expand the value and then show in the console view which pops up in the command line something like:
"-Dabc=D:\myProjects\samples\sample_report.xml"
So from what I tested on my side the ${pd} seemed to be properly expanded.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service