Telerik blogs

We constantly improve Telerik’s ASP.NET AJAX Editor control with new features requested by our clients. In the Q2 2012 beta release we added a sneak peek of its new Track Changes functionality. It resembles the idea of track changes in MS Word®, so I suppose all of you know what it is and how it behaves. Still, let’s take a look at how you can put it to good use.

How it looks

For those of you who are not familiar with this - any change in the content area (inserting, pasting, deleting or applying formatting to the content) is tracked. Content that is added is colored and is underlined (added); deleted content is marked with a strike-through line (deleted) and modified formatting is wrapped with vertical bars (|formatted|). In addition, a tooltip and a little popup with information about the applied change will appear at the bottom right corner of the browser:

ASP.NET AJAX editor - track changes feature

How to use it

Tracking is enabled by default, so any changes you make will be noted. You can disable it by clicking the Enable Track Changes Override Enable Track Changes Override button. When tracking is disabled you can still modify the content, but it will not be highlighted and the rest of your team will not have a visual indication. Once the author is done with the desired modifications he/she can accept the selected changes via the Accept Track Change Accept Track Change button. To make things faster there is also the Accept All Track Changes Accept All Track Changes button which automatically accepts all the changes. Alternatively, if you are not happy with the modifications you can reject the selected change and revert to the old content by using the Reject Track Change Reject Track Change button (or the Reject All Track Changes Reject All Track Changes for all of them at once).

The developer can control the user’s permissions according to his/her role in the system to make the feature more flexible. For example, beginner authors can have their Accept rights revoked or the Accept buttons removed so that the highlighted content is always submitted to the server for the senior staff to review). The user name is set via the Author property of the TrackChangesSettings inner tag and the CanAcceptTrackChanges property controls whether the user can accept changes.

What markup TrackChanges renders

In order for the changes to persist across server requests, additional markup is added to denote the places and formatting applied, e.g.

Markup of newly inserted content:

<ins title="Inserted by AuthorName on Thursday, May 10, 2012 10:25:12 AM" class="reU0" cite="AuthorName" timestamp="1336634712305">new content</ins>

Markup of deleted content:
<del title="Deleted by RadEditorUser on Tuesday, May 08, 2012 6:08:08 PM" class="reU0" cite="AuthorName" timestamp="1336489688549"
 name="1336489688549">TechNet</del>

Bold formatted content:
<b title="Formatted by AuthorName on Thursday, May 10, 2012 10:34:12 AM" class="reFormat reU0" author="AuthorName" timestamp="1336635252243"
 browserCommand="Bold">browsers</b>

Try it yourself

You can test the Track Changes feature and see how to configure it in the following live demo:  TrackChanges.

With the official Q2 2012 release, the track changes feature supports the following RadEditor commands:

  • Bold
  • Italic
  • Underline
  • Indent
  • Outdent
  • JustifyLeft
  • JustifyRight
  • JustifyCenter
  • JustifyFull
  • Superscript
  • Subscript
  • InsertTable
  • TableWizard
  • LinkManager

Check it out and let us know what you think – you can use the community forums, the online support system or just add a comment below. If you want to see other commands added to this list be sure to tell us, because the requests we receive will determine the priority of its implementation. Any additional feedback and suggestions are most welcome as well, for example share a real-life scenario you would use the feature in.

Download Telerik's ASP.NET AJAX Q2 2012 Beta Now


About the Author

Iana Tsolova

is Product Manager at Telerik’s DevTools division. She joined the company back in the beginning of 2008 as a Support Officer and has since occupied various positions at Telerik, including Senior Support Officer, Team Lead at one of the ASP.NET AJAX teams and Technical Support Director. Iana’s main interests are web development, reading articles related to geography, wild nature and latest renewable energy technologies.

Related Posts

Comments

Comments are disabled in preview mode.