SA Developer .NET

Welcome to SA Developer .NET Sign in | Join | Help
in Search

Sending a message via a .net Windows service

Last post 09-02-2008, 9:32 by riccardospagni. 5 replies.
Sort Posts: Previous Next
  •  08-28-2008, 14:12 14417

    Huh? [:^)] Sending a message via a .net Windows service

    Hi All

     I have an interesting dilemma.

     I need to develop a windows service that runs on a server, and monitors say a database. When a trigger condition is met it will send a message to the specified recipient.

    Problem is that message must popup on the users machine (like a Net Send message), and users are logged in via Citrix to the network.

    Is there any way of getting a message to popup like this via .net?

    Thanks:)


    --Gambit--

    Give me a lever long enough and I shall move the world.
  •  08-28-2008, 14:53 14419 in reply to 14417

    Re: Sending a message via a .net Windows service

    I would write something similar to CCTray from CruiseControl.net. Ie, an application that sits in the system tray and registers itself with a server component (be it via remoting or web services or whatever) and then pops up notifications as required.

    In fact, that project is open source, not sure under what license though, but you may even be able to retrofit CCTray's shell to suit your own porpoises.


     


    Driven Software
  •  08-29-2008, 9:49 14437 in reply to 14419

    Re: Sending a message via a .net Windows service

    Hmm..the problem with that is that the app receiving and displaying the messages would need to be on every citrix server...something our client is not happy with (If I understand what you meant correctly?)

     What they want is for the entire app to sit on a central server, and have the messages somehow sent to the citrix server the user is logged onto, with no part of the app on the citrix servers themselves....

     Which is why I am lost as to how to do it...

     


    --Gambit--

    Give me a lever long enough and I shall move the world.
  •  08-29-2008, 11:03 14440 in reply to 14437

    Re: Sending a message via a .net Windows service

    I don't have any experience dealing with citrix. I would approach them directly and ask about potential solutions - I am sure this is a problem they have solved in the past (or already know that it is unsolvable as the case may be).


    Driven Software
  •  08-29-2008, 22:33 14446 in reply to 14417

    Re: Sending a message via a .net Windows service

    I would have gone with a similar approach to what Kevin suggested. But yes you would require a client to be installed. You could always take advantage of the Messenger service under Windows if its enabled and use that through either a direct Win32 API call across the domain/AD or even use the command line NET tool.

    Alternatively if all your users will have a form of IM client installed already like MSN Messenger/Windows Live Messenger you can use the Windows Live Messenger API to send them a message. The same goes with using Jabber protocol IM clients like Google Talk, etc.



    Microsoft Xbox MVP | http://craign.net/
  •  09-02-2008, 9:32 14466 in reply to 14417

    Re: Sending a message via a .net Windows service

    Ok, net send is deprecated, and not all users have the service running on their machines. You are kinda forced to have a client running on each machine.

     

    Consider using the Enterprise Service Bus, though. Basically, your service sees something happen on the database, and pushes a message into the ESB. Any number of clients can have subscribed to that particular message type, and the ESB will push the message to all subscribers. (Simplified, but you get the idea). It's more versatile than having an XML list of end-points in your windows server, and then sending net send messages to all of them!


    And so the kief looked and lo, it was kief.
View as RSS news feed in XML
Powered by Community Server (Commercial Edition), by Telligent Systems