Currently my blog is in umbraco 6.
Now i want to switch into umbraco 7 but umbraco 6's event handler not working in umbraco 7 like Document.BeforePublish,Document.AfterPublish,Document.AfterSendToPublish etc....
so what could be the reason behind the same? please can you help ? bcz i am stuck in between this.
if my first post above was helpful and has solved your problem, please mark my first post as solution. Then other people can easier find the post with the solution.
Event handler in Umbraco 7
Hello,
Currently my blog is in umbraco 6. Now i want to switch into umbraco 7 but umbraco 6's event handler not working in umbraco 7 like Document.BeforePublish,Document.AfterPublish,Document.AfterSendToPublish etc....
so what could be the reason behind the same? please can you help ? bcz i am stuck in between this.
Awaiting your reply, With Regards...
Hi glob,
you can use the ContentService.Saving and ContentService.Saved event.
Here you can find the documentation of this services:
https://our.umbraco.org/documentation/Reference/Events-v6/
Hope this helps.
Best,
Sören
Thanks for your quick reply.
Old event handler not working in umbraco 7..right?
With Regards,
Yes
Hi glob,
if my first post above was helpful and has solved your problem, please mark my first post as solution. Then other people can easier find the post with the solution.
Thanks :-)
Best, Sören
Hi,
For version 7 you need to plugin to the ContentService on app startup. Like so:
is working on a reply...