How to remove black borders on the word document

Good day

Can you kinldy advise how can I remove the black borders on my word document.

@xesi.xp Could you please attach your actual document. Unfortunately, it is no possible to analyze the issue by screenshot. It looks like the paragraphs in your document have black background, but it is difficult to tell for sure without an actual document.

Good day

You are correct it is a black background. I have attached the word doc on this email.

Dr_Sisanda_Nkoala_MetricReport_2023-May-04.docx (201 KB)

@xesi.xp Background in this case set as shading of runs:

<w:r>
	<w:rPr>
		<w:rFonts w:ascii="Arial" w:eastAsia="Arial" w:hAnsi="Arial" w:cs="Arial" />
		<w:b w:val="0" />
		<w:bCs w:val="0" />
		<w:i w:val="0" />
		<w:iCs w:val="0" />
		<w:strike w:val="0" />
		<w:color w:val="212529" />
		<w:spacing w:val="0" />
		<w:sz w:val="16" />
		<w:szCs w:val="16" />
		<w:u w:val="none" />
		<w:shd w:val="clear" w:color="auto" w:fill="000000" />
		<w:rtl w:val="0" />
	</w:rPr>
	<w:t>Researcher Name:</w:t>
</w:r>

See w:shd. You can remove shading using code like this:

Document doc = new Document(@"C:\Temp\in.docx");

// Reset chading of all runs in the document.
doc.GetChildNodes(NodeType.Run, true).Cast<Run>().ToList()
    .ForEach(r => r.Font.Shading.BackgroundPatternColor = Color.Empty);

doc.Save(@"C:\Temp\out.docx");