Do you know of any library written in C# or compiled for .NET that I can use to find the differences between two strings (what have been inserted and what have been deleted) and then use this difference to revert the text to the original state (instead of having to save a copy of the original text)?
Share
What you’re looking for is something that solves the Longest Common Subsequence problem. There are commercial libraries that implement that, but you can find a free version that you may be able to use or adapt on CodeProject: http://www.codeproject.com/KB/recipes/DiffAlgorithmCS.aspx.
If you’re interested in the core implementation of such an algorithm, you can also find it on Wiki Books Algorithms.