Hello All,

I need some assistance on how to copy child node by child node.

I have to form a new XML in which the DICOM node has to be completely replaced with new DICOM node.

The requirement is that i have to copy
1. Measurement node with all its attributes but no child node to be copied.
2. Copy childnode Subresult with all its attributes. But child node DICOM should not be copied.

3. In place of DICOM node a new DICOM node(with updated value) will be placed.
4. Close the SubResult node

5.Copy Data node.
6.Close the Measurement node


Can somebody throw some light on how to go about this ?

I tried with <xsl:copy> ,<xsl:copy of> but I am not able to progress.

Regards
Bindhu M


PHP Code:
<Measurement MultiFetus="False" Id="m_ped_IVSd_2D" Category="cat_System" App="a_PedCard" Mode="mode_2D" UserLabel="" LocalLabel="IVSd (2D)" Tool="t_2D_Distance" ResultCount="5" Selector="sel_Avg" Bilateral="False" PrimaryResult="r_Distance">
                <
SubResult Name="r_Distance" Units="u_mm" UnitsString="cm" Precision="4" Conversion="0.1" DefaultChoice="True" UsedInCalc="True">
                    <
DICOM>
                        <
app csd="DCM" cv="125195" cm="Pediatric Cardiac Ultrasound Report"/>
                        <
group csd="SRT" cv="T-32410" cm="Interventricular septum"/>
                        <
site csd="SRT" cv="T-32410" cm="Interventricular septum"/>
                        <
concept csd="LN" cv="59089-3" cm="ROI Thickness by US"/>
                        <
mode csd="SRT" cv="G-03A2" cm="2D mode"/>
                        <
phase csd="SRT" cv="F-32011" cm="End Diastole"/>
                    </
DICOM>
                </
SubResult>
                <
Data Selector="sel_Avg">
                    <
Result Index="0">
                        <
SubResult Name="r_Distance" Value="13.7" Source="1318231201"/>
                    </
Result>
                    <
SelectedResult>
                        <
SubResult Name="r_Distance" Value="13.7"/>
                    </
SelectedResult>
                </
Data>
            </
Measurement>
        </
MasterList