[quote user="Darin Rodberg"]The textnode has 1 TextLine[/quote]
I tried your code on a standalone text node, and it works OK. I think the problem may be that the node is inside a cell. You may need to do something like this...
Do While oCell.MoveToNextElement(True) Dim oComponent As Element Set oComponent = oCell.CopyCurrentElement If oComponent.IsTextNodeElement Then Dim oNode As TextNodeElement ' Make a copy of the TextNodeElement Set oNode = oComponent.AsTextNodeElement.Clone Debug.Print "Replace text node line 1 with '" & txt & "'" oNode.textLine(1) = txt ' Global variable oCell.ReplaceCurrentElement oNode End If Loop