hello there…
where i must put this statement…Doc.MailMerge.RemoveEmptyParagraphs = True
is it before mailmerge.execute of after…
nway…thanks for the reply…
hi there…
i already try it…but it doesn’t work…
the coding i do is like this…
Public Function Execute(ByVal filterParameter As String, ByVal DocName As String, ByVal param1 As String) As Document
Dim srcDoc As Document = New Document("C:\DotNetProjs\RnD\RnDUI\DOC\" & DocName & ".doc")
Dim dstDoc As Document = srcDoc.Clone()
dstDoc.Sections.Clear()
Dim sqlStmt As String = "select......"
Dim pelesen As DataTable = Me.ExecuteDataTable(sqlStmt)
Dim i As Integer = 0
Do While i < pelesen.Rows.Count
Dim pelesenDoc As Document = srcDoc.Clone()
Dim pelesenRow As DataRow = pelesen.Rows(i)
pelesenDoc.MailMerge.Execute(pelesenRow)
Dim SqlStmt2 As String = "select......"
Dim SLA01 As DataTable = Me.ExecuteDataTable(SqlStmt2)
SLA01.TableName = "SLA01"
pelesenDoc.MailMerge.RemoveEmptyParagraphs = True
pelesenDoc.MailMerge.ExecuteWithRegions(SLA01)
AppendDoc(dstDoc, pelesenDoc)
i += 1
Loop
Return dstDoc
End Function
Hi
Thanks for your inquiry. RemoveEmptyParagraphs removes only empty paragraphs it does not remove empty rows from table.
I think the information provided in the following link could be useful for you.
Also please attach your document for testing.
Best regards.