[英]How to set xmlTag inside innerXml in c#?
我正在開發一個要求用行內的標簽替換特定單詞的應用程序。
例如考慮以下行
became an accomplished singer, musician, and hymn writer 1
1用一些文本替換,並且最終輸出應類似於下面的xml所示
<ln coord="25.78:338.56:318.35:346.89" page="1" height="574.98" left="25.78"
top="338.56" font="CrimsonText-Roman" fontsize="12.5" fonttype="Embeded">
became an accomplished singer, musician, and hymn writer in
<footnote id='1'>1 </footnote> </ln>
我嘗試了以下代碼
Line.InnerXml.Replace("<", "<").Replace(">", ">");
但是仍然在xml中獲得以下輸出
<ln coord="25.78:338.56:318.35:346.89" page="1" height="574.98" left="25.78"
top="338.56" font="CrimsonText-Roman" fontsize="12.5" fonttype="Embeded">
became an accomplished singer, musician, and hymn writer in
<footnote id='1'>1 </footnote> </ln>
如何在xml中獲取所需的輸出。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.