We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Re: Having problem when delete and insert text in table cell

Have the same issue

Hi Ramesh,

Thanks for your inquiry.

You will be notified via this forum thread once WORDSNET-14686 is resolved. We apologize for your inconvenience.

I have delete the text 2 of column ID, then insert Peter Inserted to column Name and 022022022 Inserted to column Phone.

My table has 3 columns ID, Name, Phone

Here is my code:
//Compare 2 files word
Document doc1 = new Document(document1); // doc1 is OriginalTable.docx
Document doc2 = new Document(document2); // doc2 is FormattedTable.docx
doc1.Compare(doc2, “a”, DateTime.Now);

//Get all tables in the section
foreach (Aspose.Words.Section section in doc.Sections)
{
NodeCollection tables = section.Body.GetChildNodes(NodeType.Table, true);
foreach (Aspose.Words.Tables.Table table in tables)
{
//Get the change table
if (IsChangesTable(table))
{
//Loop to get each rows
int iRow = 0;
while (iRow < table.Rows.Count)
{
Row row = table.Rows[iRow];
iRow++;
//Loop to get each cells of row
int iCell = 0;
while (iCell < row.Cells.Count)
{
Cell cell = row.Cells[iCell];
iCell++;
}
}
}
}
}
When debugging I get row.Cells.Count equals 5 instead of 3. However it doesn’t matter me. The big trouble is the order index of each cell isn’t following the order of table row.
It return me cell Peter Inserted - 2 - 022022022 Inserted instead of 2 - Peter Inserted - 022022022 Inserted

I have attach the console app you can debug line by line to get the results

Hi Ramesh,

Thanks for your inquiry. We already logged this issue as WORDSNET-14686 in our issue tracking system. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

The issues you have found earlier (filed as WORDSNET-14686) have been fixed in this Aspose.Words for .NET 17.2.0 update and this Aspose.Words for Java 17.2.0 update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.

Thank You. I Appreciate the turn around time to fix this issue.


We will download the latest version and let you know the update.

Thanks,
Ramesh

Thanks. It is working fine now.


Ramesh