PDA

View Full Version : Logging when chaining projects


GrahamS
01-12-2004, 06:18 AM
I have a number of projects that I want to call from a parent project as well as being able to run separately. I also want to use XML logging with the following requirements:

1. If the child project is run separately then it logs to its own log file (e.g. Child1 will log to Child1.log). When complete, it will display the log file (using a Transform XML step)

2. If the child project is run by the parent project then it will log to the parent's log file (e.g. Child1 will log to Parent.log). The child will not display the log file. Once all child projects have been completed then the parent will display the log file (using a Transform XML step)

I have tried to set this up passing the parents log file to the child as the LOGFILE parameter (as well as using a IS_CHILD parameter to enable the Transform XML step to be skipped in the child project).

Unfortunately I get an error when running the Transform XML step in the parent project.

Loading XML input document...
Error at line 28, position 2 loading 'C:\DOCUME~1\GRAHAM~1.SHA\LOCALS~1\Temp\bldA1.tmp' : Only one top level element is allowed in an XML document.

What am I doing wrong?

I've attached example parent and child scripts

kinook
01-12-2004, 05:49 PM
I'm not sure; it works as expected here (completes successfully). (Be aware that the HTML log in this scenario will not include the nested child project's log details [the pre-defined stylesheet only includes immediate step children of the top-level build element]).

You might try deleting the existing log file and running it again. If that doesn't help, could you send:

1) The info from Help | About | Install Info
2) Parent.log as it exists when the error occurs
3) The VBP application options file (found in Tools | File Locations | Application Options field).

To support@kinook.com. Thanks.