D
dave
Hi,
I have a protected document and I have some xml tags that can be edited
within these these tags are tags hat can't be edited. So I have looped
through the document selecting all tags and then the tag's child nodes and
running this code:
node.Range.Select()
applicationObject.Selection.Editors(Word.WdEditorType.wdEditorEveryone).Delete()
My problem is that if the child node is at the end of a table it doesn't
apply permissions properly. I've looked at the underlying xml and discovered
that the permStart and permEnd tags are incorrectly numbered at that point.
</w:r>
<ns0ata_1_Serial_Number>
<wermEnd w:id="5"/>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>test</w:t>
</w:r>
<wermStart w:id="6" w:edGrp="everyone"/>
</ns0ata_1_Serial_Number>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>.</w:t>
</w:r>
</w>
</w:tc>
</w:tr>
</w:tbl>
<w>
<wPr>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
</w>
<w:tbl>
<w:tblPr>
<w:tblW w:w="4874" w:type="pct"/>
<w:tblInd w:w="108" w:type="dxa"/>
<w:tblBorders>
<w:top w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:left w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:bottom w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:right w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
</w:tblBorders>
<w:tblLayout w:type="Fixed"/>
</w:tblPr>
<w:tblGrid>
<w:gridCol w:w="10922"/>
</w:tblGrid>
<w:tr>
<w:tc>
<w:tcPr>
<w:tcW w:w="5000" w:type="pct"/>
<w:shd w:val="pct-5" w:color="auto" w:fill="auto"
wx:bgcolor="F2F2F2"/>
</w:tcPr>
<w>
<wPr>
<w:spacing w:before="200"/>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:b/>
</w:rPr>
<w:t>Approver’s Signature</w:t>
</w:r>
</w>
<w>
<wPr>
<w:spacing w:after="100"/>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:i/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:i/>
</w:rPr>
<w:t>All Signatories (to include the Quality Signatory):</w:t>
</w:r>
</w>
<w>
<wPr>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>Your signature indicates that, as a competent reviewer, you
approve this </w:t>
</w:r>
<ns0:SCRIBELabel_0_Document_Type>
<wermEnd w:id="7"/>
<w:r>
<w:rPr>
Apologies for the formatting but as you can see the wermStart w:id="6" tag
doesn't have an end and wermEnd w:id="7" doesn't have a start.
Please help.
I have a protected document and I have some xml tags that can be edited
within these these tags are tags hat can't be edited. So I have looped
through the document selecting all tags and then the tag's child nodes and
running this code:
node.Range.Select()
applicationObject.Selection.Editors(Word.WdEditorType.wdEditorEveryone).Delete()
My problem is that if the child node is at the end of a table it doesn't
apply permissions properly. I've looked at the underlying xml and discovered
that the permStart and permEnd tags are incorrectly numbered at that point.
</w:r>
<ns0ata_1_Serial_Number>
<wermEnd w:id="5"/>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>test</w:t>
</w:r>
<wermStart w:id="6" w:edGrp="everyone"/>
</ns0ata_1_Serial_Number>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>.</w:t>
</w:r>
</w>
</w:tc>
</w:tr>
</w:tbl>
<w>
<wPr>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
</w>
<w:tbl>
<w:tblPr>
<w:tblW w:w="4874" w:type="pct"/>
<w:tblInd w:w="108" w:type="dxa"/>
<w:tblBorders>
<w:top w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:left w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:bottom w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
<w:right w:val="single" w:sz="6" wx:bdrwidth="15" w:space="0"
w:color="auto"/>
</w:tblBorders>
<w:tblLayout w:type="Fixed"/>
</w:tblPr>
<w:tblGrid>
<w:gridCol w:w="10922"/>
</w:tblGrid>
<w:tr>
<w:tc>
<w:tcPr>
<w:tcW w:w="5000" w:type="pct"/>
<w:shd w:val="pct-5" w:color="auto" w:fill="auto"
wx:bgcolor="F2F2F2"/>
</w:tcPr>
<w>
<wPr>
<w:spacing w:before="200"/>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:b/>
</w:rPr>
<w:t>Approver’s Signature</w:t>
</w:r>
</w>
<w>
<wPr>
<w:spacing w:after="100"/>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:i/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
<w:i/>
</w:rPr>
<w:t>All Signatories (to include the Quality Signatory):</w:t>
</w:r>
</w>
<w>
<wPr>
<w:ind w:left="0"/>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
</wPr>
<w:r>
<w:rPr>
<w:rFonts w:ascii="GE Inspira" w:h-ansi="GE Inspira"/>
<wx:font wx:val="GE Inspira"/>
</w:rPr>
<w:t>Your signature indicates that, as a competent reviewer, you
approve this </w:t>
</w:r>
<ns0:SCRIBELabel_0_Document_Type>
<wermEnd w:id="7"/>
<w:r>
<w:rPr>
Apologies for the formatting but as you can see the wermStart w:id="6" tag
doesn't have an end and wermEnd w:id="7" doesn't have a start.
Please help.