[C#.NET][Infopath 2010] 使用 XmlWriter 類別建立重覆表格
以前有寫過使用 XPathNavigator + XPathNodeIterator 建立重複表格
[InfoPath 2007] 如何使用程式加入列至重複表格 / How to Add Row to a Repeat Table(1)
[InfoPath 2007] 如何使用程式加入列至重複表格 / How to Add Row to a Repeat Table in Form Service(2)
今日則要使用XmlWriter來演練
1.首先先規劃好 Infopath 畫面
2. 在Loanding事件中加入以下程式
Note;my的命名空間是 http://schemas.microsoft.com/office/infopath/2003/myXSD/2010-05-16T06:00:30
執行結果
Note:跟以往一樣用用程式處理的 Repeat Table第一列都會空出來
3.處理空白列
執行 結果
範例下 載
若有謬誤,煩請告知,新手發帖請多包涵
Microsoft MVP Award 2010~2017 C# 第四季
Microsoft MVP Award 2018~2022 .NET