Strange. I've just done:
<?xml version="1.0" ?>
<project name="xmltask-demo" default="main">
<taskdef name="xmltask"
classname="com.oopsconsultancy.xmltask.ant.XmlTask"/>
<target name="main">
<property name="test" value="ok?"/>
<xmltask dest="rauch-out.xml">
<insert path="/">
<![CDATA[
<root>
${test}
</root>
]]>
</insert>
</xmltask>
</target>
</project>
which works out of the box. Does your property evaluate to XML with a root
node ?
Brian
On Fri, October 5, 2007 15:50, Holger Rauch wrote:
> Hi Brian,
>
> first of all, thanks a lot for your help. However, the <xmltask> segment
> given below produces an error.
>
> On Fri, 05 Oct 2007, Brian Agnew wrote:
>
>> >> [...]
>> >> You could instead create an in-memory XML doc using properties thus:
>> >>
>> >> <xmltask>
>> >> <insert path="/">
>> >> <![CDATA[
>> >> ${your.property}
>> >> ]]>
>> >> </insert>
>> >> </xmltask>
>> >> [...]
>
> This solution looks nice since I can do without the intermediate step of
> writing the property to a file.
>
> However, I got this error message:
>
> /home/hrauch/bazl/EmpicSuite-trunk/ant-feature-tests/xmltest-read.xml:271:
> Failed to add text to insert/paste
>
> (line 271 is the line where the <xmltask> starts).
>
> Unfortunately, the error message doesn't tell me *why* the <insert>
> failed.
> Can you think of any reason why?
>
> Thanks in advance for any info!
>
> Kind regards,
>
> Holger
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems? Stop.
> Now Search log events and configuration files using AJAX and a browser.
> Download your FREE copy of Splunk now >>
> http://get.splunk.com/_______________________________________________
> Xmltask-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/xmltask-users
>
--
Brian Agnew http://www.oopsconsultancy.com
OOPS Consultancy Ltd
Tel: +44 (0)7720 397526
Fax: +44 (0)20 8682 0012
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Xmltask-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xmltask-users