Comments events

This section provides you with an overview of the comment events that use the Telerik.Sitefinity.Services.Comments assembly. 

All content modules support comments that expose their own set of events. You can use these events to execute your own logic whenever an action on a comment is performed. This logic is executed for all modules, which support comments. The type of the items, which are commented, is passed as an argument to your event handler. With the rest of the events, you must always use interfaces to subscribe, even if the actual events that fire are concrete implementations (classes).

Following is a full list of the events supported by comments:

ICommentEvent

This interface is implemented by all events fired for Comments. Use it, if you want to subscribe to all of them.
Subscribe using the following code:

For more information, see For developers: Comments module.

ICommentCreatingEvent

This interface is implemented by all events that fire before a comment is created. Use the following code to subscribe:

ICommentCreatedEvent

This interface is implemented by all events that fire after a comment has been created. Use the following code to subscribe:

ICommentUpdatingEvent

This interface is implemented by all events that fire before a comment is updated.
Use the following code to subscribe:

In the event handler you can access the original comment item.

ICommentUpdatedEvent

This interface is implemented by all events that fire after a comment is updated.
Use the following code to subscribe:

ICommentDeletingEvent

This interface is implemented by all events that fire before a comment is deleted.
Use the following code to subscribe:

ICommentDeletedEvent

This interface is implemented by all events that fire after a comment has been deleted. Use the following code to subscribe:

Increase your Sitefinity skills by signing up for our free trainings. Get Sitefinity-certified at Progress Education Community to boost your credentials.

Get started with Integration Hub | Sitefinity Cloud | Sitefinity SaaS

This free lesson teaches administrators, marketers, and other business professionals how to use the Integration hub service to create automated workflows between Sitefinity and other business systems.

Web Security for Sitefinity Administrators

This free lesson teaches administrators the basics about protecting yor Sitefinity instance and its sites from external threats. Configure HTTPS, SSL, allow lists for trusted sites, and cookie security, among others.

Foundations of Sitefinity ASP.NET Core Development

The free on-demand video course teaches developers how to use Sitefinity .NET Core and leverage its decoupled architecture and new way of coding against the platform.

Was this article helpful?

Next article

Forms events