Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • serhio 22 posts 82 karma points
    Aug 17, 2015 @ 12:21
    serhio
    0

    Send Umbraco (4) events to an external application

    I have an Umbraco (v4.7) site installed on localhost.

    I need to do an action (let's say log to console or file) every time a umbraco node is published.

    So I need to interact with an external application (like Console or Windows Service) from an Umbraco site...

    I don't need to manipulate umbraco site with a console application, but rather respond to umbraco events with a console(or windos servie) application action.

    I have

    public class ContentEvents : umbraco.BusinessLogic.ApplicationBase
    {
    
        void PlumbEvents()
        {
            // ...
            Document.AfterPublish += new Document.PublishEventHandler(
                                                          Document_AfterPublish);
            // ...
        }
    
        void Document_AfterPublish(Document sender, PublishEventArgs e)
        {
            // HERE I NEEDD TO CALL BY EG 
            // "MyExternalApplication" + "sender" as parameter
            // where "MyExternalApplication" could be 
            // a ConsoleApplication or a WindowsService
        }
    
        // ...
    
    }
    

    is it possible to call something external from that code?

Please Sign in or register to post replies

Write your reply to:

Draft